78% adamrob-parallax-scroll

Code Review | Parallax Scroll by adamrob.co.uk

WordPress plugin Parallax Scroll by adamrob.co.uk scored 78% from 54 tests.

About plugin

  • Plugin page: adamrob-parallax-...
  • Plugin version: 3.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-5.1.0
  • WordPress version: 6.3.1
  • First release: Oct 13, 2014
  • Latest release: Mar 9, 2019
  • Number of updates: 60
  • Update frequency: every 26.8 days
  • Top authors: adamrob (100%)

Code review

54 tests

User reviews

21 reviews

Install metrics

3,000+ active / 166,600 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.27MB] [CPU: ▲0.07ms] Passed 4 tests

This is a short check of server-side resources used by Parallax Scroll by adamrob.co.uk
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.59 ▲0.1352.19 ▲11.17
Dashboard /wp-admin3.65 ▲0.3549.85 ▼10.22
Posts /wp-admin/edit.php3.70 ▲0.3555.96 ▲8.96
Add New Post /wp-admin/post-new.php6.19 ▲0.3185.37 ▼3.21
Media Library /wp-admin/upload.php3.51 ▲0.2838.40 ▲4.77
Add New /wp-admin/post-new.php?post_type=parallax_scroll3.7053.53
Parallax Scroll /wp-admin/edit.php?post_type=parallax_scroll3.6339.87

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 50 new files
Database: no new tables, 7 new options
New WordPress options
widget_theysaidso_widget
can_compress_scripts
widget_recent-posts
db_upgraded
theysaidso_admin_options
widget_recent-comments
adamrob-parallax-scroll-op-version

Browser metrics Passed 4 tests

This is an overview of browser requirements for Parallax Scroll by adamrob.co.uk
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,866 ▲13113.22 ▼1.152.06 ▲0.0648.28 ▲4.01
Dashboard /wp-admin2,227 ▲395.88 ▲0.9696.90 ▼7.8137.26 ▼11.62
Posts /wp-admin/edit.php2,116 ▲271.98 ▼0.1337.15 ▲2.2838.41 ▲4.31
Add New Post /wp-admin/post-new.php1,559 ▲1723.24 ▲4.91657.67 ▲37.9653.85 ▼0.29
Media Library /wp-admin/upload.php1,418 ▲364.24 ▲0.0597.60 ▲0.9444.23 ▼1.42
Add New /wp-admin/post-new.php?post_type=parallax_scroll2,7527.58179.7270.19
Parallax Scroll /wp-admin/edit.php?post_type=parallax_scroll1,4661.9730.6931.71

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • This plugin does not fully uninstall, leaving 7 options in the database
    • adamrob-parallax-scroll-op-version
    • db_upgraded
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-posts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 0% 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
Please take a closer look at the following
  • 7× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/adamrob-parallax-scroll/admin/partials/help/adamrob-parallax-scroll-help-posttype-fullwidth.php
    • > /wp-content/plugins/adamrob-parallax-scroll/admin/partials/help/adamrob-parallax-scroll-help-posttype-title.php
    • > /wp-content/plugins/adamrob-parallax-scroll/admin/partials/help/adamrob-parallax-scroll-help-posttype-create.php
    • > /wp-content/plugins/adamrob-parallax-scroll/admin/partials/help/adamrob-parallax-scroll-help-posttype-options.php
    • > /wp-content/plugins/adamrob-parallax-scroll/admin/partials/help/adamrob-parallax-scroll-help-posttype-style.php
    • > /wp-content/plugins/adamrob-parallax-scroll/admin/partials/help/adamrob-parallax-scroll-help-posttype-new.php
    • > /wp-content/plugins/adamrob-parallax-scroll/public/partials/adamrob-parallax-scroll-public-parallax-js-legacy.php
  • 43× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Notice
      Undefined variable: parameters in wp-content/plugins/adamrob-parallax-scroll/public/partials/adamrob-parallax-scroll-public-parallax-js-legacy.php on line 29
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/adamrob-parallax-scroll/public/partials/adamrob-parallax-scroll-public-parallax-js-legacy.php on line 50
    • > PHP Notice
      Undefined variable: parameters in wp-content/plugins/adamrob-parallax-scroll/public/partials/adamrob-parallax-scroll-public-parallax-js-legacy.php on line 34
    • > PHP Notice
      Undefined variable: parameters in wp-content/plugins/adamrob-parallax-scroll/public/partials/adamrob-parallax-scroll-public-parallax-js-legacy.php on line 45
    • > PHP Notice
      Undefined variable: parameters in wp-content/plugins/adamrob-parallax-scroll/public/partials/adamrob-parallax-scroll-public-parallax-js-legacy.php on line 50
    • > PHP Notice
      Undefined variable: parameters in wp-content/plugins/adamrob-parallax-scroll/public/partials/adamrob-parallax-scroll-public-parallax-js-legacy.php on line 38
    • > PHP Notice
      Undefined variable: parameters in wp-content/plugins/adamrob-parallax-scroll/public/partials/adamrob-parallax-scroll-public-parallax-js-legacy.php on line 19
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/adamrob-parallax-scroll/admin/partials/adamrob-parallax-scroll-meta-tab-1.php:18
    • > PHP Notice
      Undefined variable: parameters in wp-content/plugins/adamrob-parallax-scroll/public/partials/adamrob-parallax-scroll-public-parallax-js-legacy.php on line 50
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/adamrob-parallax-scroll/public/partials/adamrob-parallax-scroll-public-parallax-js-legacy.php on line 29

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Attributes that need to be fixed:
  • Plugin Name: "Plugin Name" should be replaced with the name of your plugin on the first line ( === adamrob-parallax-scroll === )
You can look at the official readme.txt

adamrob-parallax-scroll/adamrob-parallax-scroll.php 92% from 13 tests

The main file in "Parallax Scroll by adamrob.co.uk" v. 3.0.1 serves as a complement to information provided in readme.txt and as the entry point to the plugin
Please make the necessary changes and fix the following:
  • Description: The description should be shorter than 140 characters (currently 163 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Everything looks great! No dangerous files found in this plugin2,319 lines of code in 43 files:
LanguageFilesBlank linesComment linesLines of code
PHP337001,9951,670
JavaScript611391376
Markdown1400170
CSS32337103

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.26
Average class complexity7.06
▷ Minimum class complexity1.00
▷ Maximum class complexity38.00
Average method complexity2.00
▷ Minimum method complexity1.00
▷ Maximum method complexity30.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes18
▷ Abstract classes211.11%
▷ Concrete classes1688.89%
▷ Final classes00.00%
Methods109
▷ Static methods21.83%
▷ Public methods5550.46%
▷ Protected methods1513.76%
▷ Private methods3935.78%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
There were not PNG files found in your plugin