83% parallax-image

Code Review | Parallax Image

WordPress plugin Parallax Image scored 83% from 54 tests.

About plugin

  • Plugin page: parallax-image
  • Plugin version: 1.7.1
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5-6.0
  • WordPress version: 6.3.1
  • First release: Mar 27, 2017
  • Latest release: May 15, 2022
  • Number of updates: 33
  • Update frequency: every 56.7 days
  • Top authors: thehowarde (100%)

Code review

54 tests

User reviews

10 reviews

Install metrics

3,000+ active / 43,798 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▼4.32ms] Passed 4 tests

Analyzing server-side resources used by Parallax Image
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0141.09 ▼1.13
Dashboard /wp-admin3.32 ▲0.0142.72 ▼8.79
Posts /wp-admin/edit.php3.37 ▲0.0147.65 ▲0.39
Add New Post /wp-admin/post-new.php5.90 ▲0.0192.56 ▼6.00
Media Library /wp-admin/upload.php3.24 ▲0.0134.71 ▼1.35
Parallax Options /wp-admin/options-general.php?page=dd-parallax-options-page3.2032.32

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 14 new files
Database: no new tables, 7 new options
New WordPress options
dd_parallax_mce_button
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-posts
db_upgraded
can_compress_scripts
widget_recent-comments

Browser metrics Passed 4 tests

Checking browser requirements for Parallax Image
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,806 ▲7113.53 ▼0.875.02 ▲3.1643.85 ▼0.03
Dashboard /wp-admin2,215 ▲244.80 ▼1.06111.83 ▲12.3441.09 ▼4.58
Posts /wp-admin/edit.php2,092 ▲32.02 ▼0.0141.49 ▼1.3535.14 ▲0.34
Add New Post /wp-admin/post-new.php1,533 ▼123.38 ▼0.25658.47 ▲72.3751.63 ▲1.13
Media Library /wp-admin/upload.php1,394 ▲124.18 ▲0.0495.07 ▼2.0343.52 ▲1.38
Parallax Options /wp-admin/options-general.php?page=dd-parallax-options-page9052.0325.7852.58

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • widget_recent-comments
    • widget_theysaidso_widget
    • dd_parallax_mce_button
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though no errors were found, this is by no means an exhaustive test

SRP 50% 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 fix the following items
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/parallax-image/assets/admin-scripts.php:17
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/parallax-image/assets/shortcode.php:9

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser issues were found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Please fix the following attributes: The official readme.txt might help

parallax-image/parallax-image.php 85% from 13 tests

The entry point to "Parallax Image" version 1.7.1 is a PHP file that has certain tags in its header comment area
Please take the time to fix the following:
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 145 characters long)
  • Requires PHP: The required version number did not match the one declared in readme.txt ("5.4" instead of "5.6")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Everything looks great! No dangerous files found in this plugin1,071 lines of code in 11 files:
LanguageFilesBlank linesComment linesLines of code
PHP5196675900
JavaScript33588
Markdown138063
CSS21020

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.74
Average class complexity134.00
▷ Minimum class complexity134.00
▷ Maximum class complexity134.00
Average method complexity4.80
▷ Minimum method complexity1.00
▷ Maximum method complexity77.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods35
▷ Static methods925.71%
▷ Public methods3394.29%
▷ Protected methods25.71%
▷ Private methods00.00%
Functions10
▷ Named functions10100.00%
▷ Anonymous functions00.00%
Constants10
▷ Global constants110.00%
▷ Class constants990.00%
▷ Public constants9100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
There were not PNG files found in your plugin