94% shopp-product-page-browser-sppb

Code Review | Shopp Product Page Browser

WordPress plugin Shopp Product Page Browser scored 94% from 54 tests.

About plugin

  • Plugin page: shopp-product-pag...
  • Plugin version: 1.3.3
  • PHP version: 7.4.16
  • WordPress compatibility: 2.0.2-4.7.4
  • WordPress version: 5.8.1
  • First release: Nov 5, 2011
  • Latest release: Apr 21, 2017
  • Number of updates: 69
  • Update frequency: every 28.9 days
  • Top authors: Shoppdeveloper.com (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 5,961 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.00MB] [CPU: ▼139.97ms] Passed 4 tests

A check of server-side resources used by Shopp Product Page Browser
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /2.84 ▲0.1233.69 ▲9.88
Dashboard /wp-admin3.06 ▲0.0146.56 ▼2.84
Posts /wp-admin/edit.php3.11 ▲0.0145.34 ▼1.50
Add New Post /wp-admin/post-new.php5.42 ▼0.0192.29 ▼556.24
Media Library /wp-admin/upload.php3.00 ▲0.0032.87 ▲0.71

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 11 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

Shopp Product Page Browser: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,679 ▲8315.96 ▲0.0017.79 ▲7.9547.09 ▼4.66
Dashboard /wp-admin2,969 ▲385.91 ▼0.19145.86 ▲0.24104.64 ▼1.64
Posts /wp-admin/edit.php2,739 ▼02.72 ▼0.0072.01 ▲6.6294.88 ▲4.33
Add New Post /wp-admin/post-new.php1,676 ▼618.93 ▲0.17434.17 ▲31.43118.07 ▲9.22
Media Library /wp-admin/upload.php1,810 ▲655.04 ▲0.05143.84 ▼85.36115.83 ▼7.25

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The plugin uninstalled completely, with no zombie files or tables

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
The smoke test was a success, however most plugin functionality was not tested

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
Almost there! Just fix the following items
  • 3× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/shopp-product-page-browser-sppb/includes/load-scripts.php:24
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/shopp-product-page-browser-sppb/includes/other_plugins.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function shopp_setting() in wp-content/plugins/shopp-product-page-browser-sppb/includes/settings.php:14

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser issues were found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
8 plugin tags: previous, webshop, browse, ecommerce, products...

shopp-product-page-browser-sppb/sppb.php 92% from 13 tests

This is the main PHP file of "Shopp Product Page Browser" version 1.3.3, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please make the necessary changes and fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("shopp-product-page-browser-sppb.php" instead of "sppb.php")

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 plugin516 lines of code in 10 files:
LanguageFilesBlank linesComment linesLines of code
PHP813480509
CSS1386
JavaScript1001

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.25
Average class complexity6.00
▷ Minimum class complexity5.00
▷ Maximum class complexity7.00
Average method complexity2.00
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods10
▷ Static methods00.00%
▷ Public methods10100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions8
▷ Named functions8100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
No PNG images were found in this plugin