10% simple-slideshow-manager

Code Review | Simple Slideshow Manager

WordPress plugin Simple Slideshow Manager scored 10% from 54 tests.

About plugin

  • Plugin page: simple-slideshow-...
  • Plugin version: 2.3.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-5.4.1
  • WordPress version: 5.8.1
  • First release: Jul 15, 2013
  • Latest release: May 19, 2020
  • Number of updates: 47
  • Update frequency: every 53.2 days
  • Top authors: Acurax (100%)

Code review

54 tests

User reviews

58 reviews

Install metrics

4,000+ active / 101,137 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
It is recommended to fix the following installer errors
  • This plugin did not install gracefully
    • > Deprecated in wp-content/plugins/simple-slideshow-manager/function.php+1013
    Methods with the same name as their class will not be constructors in a future version of PHP; Acx_Slideshow_Widget has a deprecated constructor

Server metrics [RAM: ▼1.21MB] [CPU: ▼194.15ms] Passed 4 tests

This is a short check of server-side resources used by Simple Slideshow Manager
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /2.43 ▼0.417.69 ▼20.52
Dashboard /wp-admin2.44 ▼0.626.49 ▼36.35
Posts /wp-admin/edit.php2.45 ▼0.677.51 ▼40.11
Add New Post /wp-admin/post-new.php2.44 ▼2.996.53 ▼668.19
Media Library /wp-admin/upload.php2.45 ▼0.576.03 ▼31.94
Misc /wp-admin/admin.php?page=Acurax-Slideshow-Misc2.456.14
Help /wp-admin/admin.php?page=Acurax-Slideshow-Help2.458.21
Add Images /wp-admin/admin.php?page=Acurax-Slideshow-Add-Images2.456.61
Code Generator /wp-admin/admin.php?page=Acurax-Slideshow-Generate-Shortcode2.456.79
Slideshow /wp-admin/admin.php?page=Acurax-Slideshow-Settings2.456.19
Add-ons /wp-admin/admin.php?page=Acurax-Slideshow-Add-ons2.4511.96

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 85 new files
Database: no new tables, 5 new options
New WordPress options
acx_slideshow_installed_date
widget_acx_slideshow_widget
acx_slideshow_version
acx_slideshow_gallery_data
acx_slideshow_imageupload_complete_data

Browser metrics Passed 4 tests

A check of browser resources used by Simple Slideshow Manager
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /4,115 ▲50917.75 ▲1.8512.10 ▼0.7050.91 ▼2.18
Dashboard /wp-admin3,246 ▲3157.93 ▲1.90151.97 ▲12.16133.89 ▲24.17
Posts /wp-admin/edit.php3,046 ▲3104.25 ▲1.5381.81 ▲17.84112.27 ▲17.86
Add New Post /wp-admin/post-new.php1,912 ▲23619.15 ▲0.28367.01 ▼16.73114.91 ▲8.09
Media Library /wp-admin/upload.php1,879 ▲694.76 ▼0.27119.68 ▼27.29139.06 ▲15.53
Misc /wp-admin/admin.php?page=Acurax-Slideshow-Misc4,0463.4168.86103.55
Help /wp-admin/admin.php?page=Acurax-Slideshow-Help3,9603.4069.2199.79
Add Images /wp-admin/admin.php?page=Acurax-Slideshow-Add-Images3,9973.4168.2190.52
Code Generator /wp-admin/admin.php?page=Acurax-Slideshow-Generate-Shortcode4,0303.4269.69105.98
Slideshow /wp-admin/admin.php?page=Acurax-Slideshow-Settings3,9993.4371.3490.66
Add-ons /wp-admin/admin.php?page=Acurax-Slideshow-Add-ons1,5173.3367.5386.60

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
You still need to fix the following
  • Uninstall procedure validation failed for this plugin
    • > Deprecated in wp-content/plugins/simple-slideshow-manager/function.php+1013
    Methods with the same name as their class will not be constructors in a future version of PHP; Acx_Slideshow_Widget has a deprecated constructor
  • Zombie WordPress options detected upon uninstall: 5 options
    • widget_acx_slideshow_widget
    • acx_slideshow_imageupload_complete_data
    • acx_slideshow_gallery_data
    • acx_slideshow_installed_date
    • acx_slideshow_version

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
These server-side errors were triggered
  • 7 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=Acurax-Slideshow-Add-ons
    • > Deprecated in wp-content/plugins/simple-slideshow-manager/function.php+1013
    Methods with the same name as their class will not be constructors in a future version of PHP; Acx_Slideshow_Widget has a deprecated constructor
  • 7 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=Acurax-Slideshow-Add-ons
    • > Deprecated in wp-content/plugins/simple-slideshow-manager/function.php+1126
    Function create_function() is deprecated
    • > GET request to /wp-admin/admin.php?page=Acurax-Slideshow-Generate-Shortcode
    • > Warning in wp-content/plugins/simple-slideshow-manager/includes/option_fields.php+1609
    Invalid argument supplied for foreach()

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Almost there! Just fix the following items
  • 11× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function acx_slideshow_hook_function() in wp-content/plugins/simple-slideshow-manager/includes/acx_slideshow_addons.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function acx_slideshow_hook_function() in wp-content/plugins/simple-slideshow-manager/includes/acx_slideshow_managegallery.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/simple-slideshow-manager/includes/option_fields.php:19
    • > PHP Fatal error
      Uncaught Error: Call to undefined function acx_slideshow_hook_function() in wp-content/plugins/simple-slideshow-manager/includes/help.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/simple-slideshow-manager/acx_slideshow_main.php:27
    • > PHP Fatal error
      Uncaught Error: Call to undefined function acx_slideshow_hook_function() in wp-content/plugins/simple-slideshow-manager/includes/acx_slideshow_option.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function acx_slideshow_hook_function() in wp-content/plugins/simple-slideshow-manager/includes/simple-slideshow-manager-misc.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function acx_slideshow_hook_function() in wp-content/plugins/simple-slideshow-manager/includes/acx_slideshow_generate_shortcode.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/simple-slideshow-manager/includes/acx-slideshow-licence-activation.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/simple-slideshow-manager/function.php:14

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 90% 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
Attributes that need to be fixed:
  • Tags: Please delete some tags, you are using 14 tag instead of maximum 10
The official readme.txt is a good inspiration

simple-slideshow-manager/acx_slideshow_main.php 85% from 13 tests

The main PHP file in "Simple Slideshow Manager" ver. 2.3.1 adds more information about the plugin and also serves as the entry point for this plugin
It is important to fix the following:
  • Description: The description should be shorter than 140 characters (currently 150 characters long)
  • Main file name: Name the main plugin file the same as the plugin slug ("simple-slideshow-manager.php" instead of "acx_slideshow_main.php")

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
No dangerous file extensions were detected10,021 lines of code in 19 files:
LanguageFilesBlank linesComment linesLines of code
PHP128691,7167,162
CSS471212,114
SVG300745

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.36
Average class complexity43.12
▷ Minimum class complexity1.00
▷ Maximum class complexity206.00
Average method complexity4.21
▷ Minimum method complexity1.00
▷ Maximum method complexity34.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes8
▷ Abstract classes00.00%
▷ Concrete classes8100.00%
▷ Final classes00.00%
Methods105
▷ Static methods54.76%
▷ Public methods8278.10%
▷ Protected methods2321.90%
▷ Private methods00.00%
Functions209
▷ Named functions209100.00%
▷ Anonymous functions00.00%
Constants6
▷ Global constants350.00%
▷ Class constants350.00%
▷ Public constants3100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
39 PNG files occupy 0.24MB with 0.07MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/Play-1-Normal-Red-icon.png1.34KB1.32KB▼ 1.38%
images/yellow.png20.55KB5.51KB▼ 73.17%
images/next.png3.36KB0.86KB▼ 74.37%
images/refresh.png0.57KB0.79KB0.00%
images/upload_video.png0.98KB1.12KB0.00%