93% jano-wp-woocommerce-advanced-search

Code Review | jano wp and woocommerce advanced search

WordPress plugin jano wp and woocommerce advanced search scored 93% from 54 tests.

About plugin

  • Plugin page: jano-wp-woocommer...
  • Plugin version: 1.5
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.2
  • WordPress version: 5.8.1
  • First release: Jun 3, 2015
  • Latest release: Nov 19, 2015
  • Number of updates: 35
  • Update frequency: every 4.8 days
  • Top authors: janothemes (100%)

Code review

54 tests

User reviews

5 reviews

Install metrics

100+ active / 4,174 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

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

A check of server-side resources used by jano wp and woocommerce advanced search
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /2.85 ▲0.0238.44 ▲3.80
Dashboard /wp-admin3.07 ▲0.0145.73 ▲4.64
Posts /wp-admin/edit.php3.12 ▲0.0147.72 ▲2.37
Add New Post /wp-admin/post-new.php5.42 ▼0.0194.87 ▼544.24
Media Library /wp-admin/upload.php3.01 ▲0.0131.21 ▲1.05

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

How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 23 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

An overview of browser requirements for jano wp and woocommerce advanced search
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,814 ▲24216.12 ▲0.7412.48 ▲1.9246.00 ▼0.96
Dashboard /wp-admin2,973 ▲426.08 ▲0.15142.20 ▼7.8897.95 ▼7.66
Posts /wp-admin/edit.php2,739 ▼02.73 ▲0.0168.41 ▼2.7490.38 ▲8.61
Add New Post /wp-admin/post-new.php1,683 ▼018.78 ▲0.01441.54 ▲39.36105.59 ▼12.05
Media Library /wp-admin/upload.php1,748 ▼595.02 ▲0.01156.93 ▲5.50119.21 ▲4.30

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The plugin uninstalled successfully, without leaving any zombie files or tables

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)
The smoke test was a success, however most plugin functionality was not tested

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 take a closer look at the following
  • 2× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugins_url() in wp-content/plugins/jano-wp-woocommerce-advanced-search/plugin.php:18
    • > PHP Fatal error
      Uncaught Error: Call to undefined function site_url() in wp-content/plugins/jano-wp-woocommerce-advanced-search/template/template.php:3

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
These attributes need to be fixed:
  • Tags: Please reduce the number of tags, currently 20 tag instead of maximum 10
  • Donate link: Invalid URI ("")
You can look at the official readme.txt

jano-wp-woocommerce-advanced-search/plugin.php 92% from 13 tests

"jano wp and woocommerce advanced search" version 1.5's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please take the time to fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("jano-wp-woocommerce-advanced-search.php" instead of "plugin.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
No dangerous file extensions were detected538 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
CSS21321181
PHP41017168
JavaScript11000146
PO File151522
SVG10021

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.28
Average class complexity10.00
▷ Minimum class complexity10.00
▷ Maximum class complexity10.00
Average method complexity2.50
▷ Minimum method complexity1.00
▷ Maximum method complexity8.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods6
▷ Static methods00.00%
▷ Public methods6100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants4100.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
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/img/search-icon.png1.60KB0.90KB▼ 43.98%