66% wp-1-slider

Code Review | WordPress Slider Plugin - WP 1 Slider

WordPress plugin WordPress Slider Plugin - WP 1 Slider scored 66% from 54 tests.

About plugin

  • Plugin page: wp-1-slider
  • Plugin version: 1.3.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.8-5.8
  • WordPress version: 5.9.2
  • First release: May 17, 2016
  • Latest release: Oct 6, 2021
  • Number of updates: 68
  • Update frequency: every 29.0 days
  • Top authors: Access Keys (100%)

Code review

54 tests

User reviews

10 reviews

Install metrics

8,000+ active / 163,159 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.24MB] [CPU: ▼349.49ms] Passed 4 tests

Server-side resources used by WordPress Slider Plugin - WP 1 Slider
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.80 ▲0.2861.67 ▲2.55
Dashboard /wp-admin3.67 ▲0.2740.28 ▼15.44
Posts /wp-admin/edit.php3.89 ▲0.2544.12 ▼1.49
Add New Post /wp-admin/post-new.php7.11 ▲0.1499.29 ▼1,383.13
Media Library /wp-admin/upload.php3.59 ▲0.3027.82 ▲2.11
All WP 1 Sliders /wp-admin/edit.php?post_type=wp1slider3.6732.39
About The Plugin /wp-admin/edit.php?post_type=wp1slider&page=wp1s-about-page3.6139.00
Documentation /wp-admin/edit.php?post_type=wp1slider&page=wp1s-documentation-wp3.3723.54
Add New /wp-admin/post-new.php?post_type=wp1slider4.1154.25

Server storage [IO: ▲4.68MB] [DB: ▲0.00MB] Passed 3 tests

Input-output and database impact of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 132 new files
Database: no new tables, 1 new option
New WordPress options
widget_wp1s_widget

Browser metrics Passed 4 tests

A check of browser resources used by WordPress Slider Plugin - WP 1 Slider
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /4,236 ▲48218.52 ▲2.599.58 ▲3.202.05 ▼1.26
Dashboard /wp-admin3,211 ▲3538.40 ▲2.27173.78 ▲35.2350.08 ▼116.59
Posts /wp-admin/edit.php3,055 ▲3615.48 ▲2.2587.14 ▲11.3547.75 ▼108.35
Add New Post /wp-admin/post-new.php1,768 ▲4916.87 ▼0.63406.84 ▼57.06117.88 ▼58.28
Media Library /wp-admin/upload.php1,834 ▲1365.96 ▲0.42130.00 ▼16.86163.88 ▼55.35
All WP 1 Sliders /wp-admin/edit.php?post_type=wp1slider1,7545.4178.0445.25
About The Plugin /wp-admin/edit.php?post_type=wp1slider&page=wp1s-about-page1,94712.17250.41122.12
Documentation /wp-admin/edit.php?post_type=wp1slider&page=wp1s-documentation-wp1,3959.66362.10231.23
Add New /wp-admin/post-new.php?post_type=wp1slider8,0707.54238.6451.39

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Please fix the following items
  • Zombie WordPress options detected upon uninstall: 1 option
    • widget_wp1s_widget

Smoke tests 0% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Smoke test failed, please fix the following
    • > GET request to /wp-admin/post-new.php?post_type=wp1slider
    • > Notice in wp-content/plugins/wp-1-slider/inc/wp1s-slide-general-settings.php+229
    Undefined index: wp1s_show_caption_widget
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/post-new.php?post_type=wp1slider
    • > Notice in wp-content/plugins/wp-1-slider/inc/wp1s-slide-general-settings.php+462
    Trying to access array offset on value of type null
    • > GET request to /wp-admin/post-new.php?post_type=wp1slider
    • > Notice in wp-content/plugins/wp-1-slider/inc/wp1s-slide-general-settings.php+462
    Undefined index: wp1s_show_thumb_widget

SRP 0% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please take a closer look at the following
  • 13× PHP files perform the task of outputting text when accessed with GET requests (only 10 are shown):
    • > /wp-content/plugins/wp-1-slider/inc/wp1s-shortcode.php
    • > /wp-content/plugins/wp-1-slider/inc/wp1s-form-footer.php
    • > /wp-content/plugins/wp-1-slider/inc/wp1s-slide-meta.php
    • > /wp-content/plugins/wp-1-slider/inc/wp1s-resizer.php
    • > /wp-content/plugins/wp-1-slider/inc/admin/wp1s-about-page.php
    • > /wp-content/plugins/wp-1-slider/inc/wp1s-slide-meta-option.php
    • > /wp-content/plugins/wp-1-slider/wp-1-slider.php
    • > /wp-content/plugins/wp-1-slider/inc/admin/wp1s-stuff-page.php
    • > /wp-content/plugins/wp-1-slider/inc/wp1s-upgrade-pro.php
    • > /wp-content/plugins/wp-1-slider/inc/wp1s-register-post.php
  • 4× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/wp-1-slider/inc/wp1s-block/wp1s-block-init.php:20
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/wp-1-slider/inc/wp1s-shortcode-popup.php:11
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/wp-1-slider/inc/admin/header.php:9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/wp-1-slider/inc/wp1s-inline-style.php:3

User-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Please take a look at the following user-side issues
    • > GET request to /wp-admin/edit.php?post_type=wp1slider&page=wp1s-documentation-wp
    • > Javascript (severe) in unknown
    https://accesspressthemes.com/documentation/wp-1-slider/ - Access to script at 'https://embed.tawk.to/60cc2bbb65b7290ac63693ec/1f8eollms' from origin 'https://accesspressthemes.com' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource.
    • > GET request to /wp-admin/edit.php?post_type=wp1slider&page=wp1s-documentation-wp
    • > Network (severe)
    https://embed.tawk.to/60cc2bbb65b7290ac63693ec/1f8eollms - Failed to load resource: net::ERR_FAILED

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
These attributes need to be fixed:
  • Tags: Please reduce the number of tags, currently 13 tag instead of maximum 10
Please take inspiration from this readme.txt

wp-1-slider/wp-1-slider.php Passed 13 tests

The primary PHP file in "WordPress Slider Plugin - WP 1 Slider" version 1.3.0 is used by WordPress to initiate all plugin functionality
116 characters long description:
An ultimate WordPress slider Plugin | Many layout | Many useful features | Many configuration options | Easy to use!

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Good job! No executable or dangerous file extensions detected4,613 lines of code in 28 files:
LanguageFilesBlank linesComment linesLines of code
CSS490552,015
PHP182501471,975
JavaScript64262623

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.41
Average class complexity38.25
▷ Minimum class complexity1.00
▷ Maximum class complexity108.00
Average method complexity4.47
▷ Minimum method complexity1.00
▷ Maximum method complexity40.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes4
▷ Abstract classes00.00%
▷ Concrete classes4100.00%
▷ Final classes00.00%
Methods43
▷ Static methods12.33%
▷ Public methods4195.35%
▷ Protected methods00.00%
▷ Private methods24.65%
Functions6
▷ Named functions583.33%
▷ Anonymous functions116.67%
Constants6
▷ Global constants6100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
66 PNG files occupy 1.69MB with 1.06MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/pager/pager-4-preview.png0.95KB0.11KB▼ 87.93%
images/pinterest.png2.17KB1.25KB▼ 42.30%
images/arrow/arrow-type-3.png3.23KB1.83KB▼ 43.52%
images/theme.png52.01KB17.38KB▼ 66.59%
images/arrow/thumb-arrow-2.png1.14KB0.31KB▼ 72.85%