10% wp-fading-content-slider

Code Review | WP Fading Content Slider

WordPress plugin WP Fading Content Slider scored10%from 54 tests.

About plugin

  • Plugin page: wp-fading-content...
  • Plugin version: 0.2.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.5.1
  • WordPress version: 6.3.1
  • First release: Nov 28, 2012
  • Latest release: Mar 26, 2013
  • Number of updates: 17
  • Update frequency: every 13.2 days
  • Top authors: wp-maverick (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /3,261 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
It is recommended to fix the following installer errors
  • Install procedure had errors
    • > User notice in wp-includes/functions.php+5905
    Function register_uninstall_hook was called incorrectly. Only a static class method or function can be used in an uninstall hook. Please see Debugging in WordPress for more information. (This message was added in version 3.1.0.)

Server metrics [RAM: ▼1.90MB] [CPU: ▼59.19ms] Passed 4 tests

An overview of server-side resources used by WP Fading Content Slider
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /2.10 ▼1.365.13 ▼36.65
Dashboard /wp-admin2.12 ▼1.236.62 ▼58.52
Posts /wp-admin/edit.php2.12 ▼1.245.81 ▼47.02
Add New Post /wp-admin/post-new.php2.12 ▼3.775.38 ▼94.55
Media Library /wp-admin/upload.php2.12 ▼1.116.56 ▼30.74
WP Fading Content Slider /wp-admin/options-general.php?page=wp-fading-content-slider/views/admin.php2.125.77

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

A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 15 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_theysaidso_widget
widget_recent-comments
can_compress_scripts
widget_recent-posts
theysaidso_admin_options

Browser metrics Passed 4 tests

An overview of browser requirements for WP Fading Content Slider
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,904 ▲14313.64 ▼0.675.92 ▲3.8543.03 ▼2.51
Dashboard /wp-admin2,224 ▲245.80 ▼0.07100.78 ▼3.5438.13 ▼3.02
Posts /wp-admin/edit.php2,103 ▲32.05 ▲0.0337.16 ▼6.6732.37 ▼6.11
Add New Post /wp-admin/post-new.php6,247 ▲4,71619.27 ▼3.91848.27 ▲155.9857.01 ▲0.70
Media Library /wp-admin/upload.php1,409 ▲124.32 ▲0.08100.39 ▼3.7546.50 ▲0.44
WP Fading Content Slider /wp-admin/options-general.php?page=wp-fading-content-slider/views/admin.php1,0742.1524.7133.03

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • The plugin did not uninstall gracefully
    • > User notice in wp-includes/functions.php+5905
    Function register_uninstall_hook was called incorrectly. Only a static class method or function can be used in an uninstall hook. Please see Debugging in WordPress for more information. (This message was added in version 3.1.0.)
  • Zombie WordPress options detected upon uninstall: 6 options
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Almost there, just fix the following server-side errors
    • > GET request to /wp-admin/options-general.php?page=wp-fading-content-slider/views/admin.php
    • > User notice in wp-includes/functions.php+5905
    Function register_uninstall_hook was called incorrectly. Only a static class method or function can be used in an uninstall hook. Please see Debugging in WordPress for more information. (This message was added in version 3.1.0.)
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=wp-fading-content-slider/views/admin.php
    • > User deprecated in wp-includes/functions.php+5737
    Function has_cap was called with an argument that is deprecated since version 2.0.0! Usage of user levels is deprecated. Use capabilities instead.
    • > GET request to /wp-admin/options-general.php?page=wp-fading-content-slider/views/admin.php
    • > Notice in wp-content/plugins/wp-fading-content-slider/views/admin.php+2
    Undefined variable: options_page

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
The following issues need your attention
  • 3× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/wp-fading-content-slider/views/admin.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wp-fading-content-slider/wp-fading-content-slider.php:25
    • > PHP Notice
      Undefined variable: options_page in wp-content/plugins/wp-fading-content-slider/views/admin.php on line 2

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
Attributes that need to be fixed:
  • Screenshots: Add images for these screenshots: #1 (The slider displayed on [MBA Multimedia's blog](http://blog.mba-multimedia.com/)), #2 (The new box in the post/page edit screen), #3 (The plugin admin panel)
Please take inspiration from this readme.txt

wp-fading-content-slider/wp-fading-content-slider.php Passed 13 tests

The primary PHP file in "WP Fading Content Slider" version 0.2.2 is used by WordPress to initiate all plugin functionality
76 characters long description:
A customizable JQuery content slider with CSS3 animations and fading effects

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Good job! No executable or dangerous file extensions detected733 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP38393375
CSS24519255
PO File1343598
JavaScript1015

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.23
Average class complexity22.00
▷ Minimum class complexity22.00
▷ Maximum class complexity22.00
Average method complexity2.24
▷ Minimum method complexity1.00
▷ Maximum method complexity17.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods17
▷ Static methods00.00%
▷ Public methods17100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
4 PNG files occupy 0.30MB with 0.12MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-2.png24.38KB9.05KB▼ 62.86%
images/sprite.png2.71KB1.71KB▼ 36.87%
screenshot-3.png134.70KB48.97KB▼ 63.65%
screenshot-1.png150.44KB149.67KB▼ 0.51%