68% ui-slider-filter-by-price

Code Review | Ui Slider Filter By Price

WordPress plugin Ui Slider Filter By Price scored68%from 54 tests.

About plugin

  • Plugin page: ui-slider-filter-...
  • Plugin version: 1.1
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.1
  • WordPress version: 6.3.1
  • First release: Aug 5, 2015
  • Latest release: Feb 1, 2023
  • Number of updates: 34
  • Update frequency: every 80.5 days
  • Top authors: mansurahamed (61.76%)chenyenming (32.35%)Otto42 (11.76%)

Code review

54 tests

User reviews

2 reviews

Install metrics

90+ active /6,711 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully

Server metrics [RAM: ▲0.16MB] [CPU: ▼5.46ms] Passed 4 tests

Analyzing server-side resources used by Ui Slider Filter By Price
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.62 ▲0.1638.81 ▼1.49
Dashboard /wp-admin3.46 ▲0.1651.34 ▼0.08
Posts /wp-admin/edit.php3.57 ▲0.2250.44 ▲3.18
Add New Post /wp-admin/post-new.php6.04 ▲0.1685.99 ▼23.43
Media Library /wp-admin/upload.php3.38 ▲0.1638.31 ▲4.55
All Sliders /wp-admin/admin.php?page=ui-sliders3.3534.82
Add New /wp-admin/admin.php?page=add-slider3.3633.37
Uninstall /wp-admin/admin.php?page=uninstall-ui-slider3.3529.15

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 42 new files
Database: 1 new table, 6 new options
New tables
wp_price_ui_slider
New WordPress options
widget_theysaidso_widget
widget_recent-posts
db_upgraded
widget_recent-comments
can_compress_scripts
theysaidso_admin_options

Browser metrics Passed 4 tests

An overview of browser requirements for Ui Slider Filter By Price
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,918 ▲17213.62 ▼0.739.47 ▲7.5539.93 ▼6.06
Dashboard /wp-admin2,236 ▲485.83 ▲0.99108.94 ▲1.1988.78 ▲40.91
Posts /wp-admin/edit.php2,122 ▲362.02 ▼0.0434.44 ▼2.8834.77 ▼2.15
Add New Post /wp-admin/post-new.php6,246 ▲4,70418.86 ▲0.821,023.35 ▲341.4560.89 ▼0.12
Media Library /wp-admin/upload.php1,412 ▲244.16 ▲0.0498.64 ▼9.6967.02 ▲23.44
All Sliders /wp-admin/admin.php?page=ui-sliders9372.2127.4736.86
Add New /wp-admin/admin.php?page=add-slider1,1702.4650.2891.52
Uninstall /wp-admin/admin.php?page=uninstall-ui-slider8272.0225.8728.41

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
These items require your attention
  • The uninstall procedure failed, leaving 1 table in the database
    • wp_price_ui_slider
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-comments
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options
    • can_compress_scripts

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 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
  • 5× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/ui-slider-filter-by-price/sliders/Sliders.php:2
    • > PHP Fatal error
      Uncaught Error: Class 'Sliders' not found in wp-content/plugins/ui-slider-filter-by-price/sliders/3d/class/Slider3d.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugins_url() in wp-content/plugins/ui-slider-filter-by-price/ui_slider_filter_by_price.php:11
    • > PHP Fatal error
      Uncaught Error: Class 'Sliders' not found in wp-content/plugins/ui-slider-filter-by-price/sliders/classic/class/SliderClassic.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/ui-slider-filter-by-price/classes/ShortCode.php:2

User-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Please fix the following user-side errors
    • > GET request to /wp-admin/admin.php?page=add-slider
    • > Network (severe)
    http://localhost/test/wp-includes/js/jquery/ui/core.min.js?ver=1.11.4 - Failed to load resource: the server responded with a status of 404 (Not Found)
    • > GET request to /wp-admin/admin.php?page=add-slider
    • > Network (severe)
    http://localhost/test/wp-includes/js/jquery/ui/slider.min.js?ver=1.11.4 - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
Attributes that require attention:
  • Tags: Please delete some tags, you are using 11 tag instead of maximum 10
You can take inspiration from this readme.txt

ui-slider-filter-by-price/ui_slider_filter_by_price.php 85% from 13 tests

Analyzing the main PHP file in "Ui Slider Filter By Price" version 1.1
The following require your attention:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("ui-slider-filter-by-price.php" instead of "ui_slider_filter_by_price.php")
  • Description: The description should be shorter than 140 characters (currently 338 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 plugin17,432 lines of code in 26 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript72,9781,79914,946
CSS101922011,214
PHP8189771,017
SVG100255

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.21
Average class complexity9.89
▷ Minimum class complexity1.00
▷ Maximum class complexity25.00
Average method complexity3.00
▷ Minimum method complexity1.00
▷ Maximum method complexity21.00
Code structure
Namespaces0
Interfaces1
Traits0
Classes8
▷ Abstract classes00.00%
▷ Concrete classes8100.00%
▷ Final classes00.00%
Methods41
▷ Static methods512.20%
▷ Public methods41100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
8 PNG files occupy 0.11MB with 0.07MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/button_check.png4.66KB1.57KB▼ 66.23%
extensions/colorpicker/jquery.minicolors.png75.64KB34.31KB▼ 54.64%
images/DONATE.png11.04KB2.39KB▼ 78.35%
images/icon.png3.28KB0.92KB▼ 71.88%
sliders/3d/images/icon.png9.11KB5.23KB▼ 42.60%