78% range-slider-field-for-contact-form-7

Code Review | Range Slider Field for Contact Form 7

WordPress plugin Range Slider Field for Contact Form 7 scored78%from 54 tests.

About plugin

  • Plugin page: range-slider-fiel...
  • Plugin version: 1.0
  • PHP compatiblity: 5.0+
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Jul 12, 2022
  • Latest release: Oct 2, 2023
  • Number of updates: 6
  • Update frequency: every 74.5 days
  • Top authors: silverplugins217 (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

90+ active /770 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

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

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

Analyzing server-side resources used by Range Slider Field for Contact Form 7
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.54 ▲0.0835.91 ▼2.42
Dashboard /wp-admin3.38 ▲0.0745.65 ▼2.18
Posts /wp-admin/edit.php3.43 ▲0.0744.83 ▼4.15
Add New Post /wp-admin/post-new.php5.96 ▲0.0788.75 ▼6.09
Media Library /wp-admin/upload.php3.30 ▲0.0740.17 ▲5.36

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 18 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
db_upgraded
widget_recent-comments
widget_theysaidso_widget
theysaidso_admin_options
can_compress_scripts

Browser metrics Passed 4 tests

Range Slider Field for Contact Form 7: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,910 ▲17514.45 ▲0.0712.69 ▲10.9635.46 ▼7.33
Dashboard /wp-admin2,217 ▲254.89 ▼0.03111.54 ▼2.9142.23 ▼2.15
Posts /wp-admin/edit.php2,100 ▲112.01 ▼0.0443.65 ▲6.1137.42 ▲1.78
Add New Post /wp-admin/post-new.php1,543 ▲2923.41 ▲5.96666.98 ▲17.0156.24 ▼5.45
Media Library /wp-admin/upload.php1,402 ▲144.17 ▲0.0396.97 ▼1.7243.38 ▲0.52

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-comments

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 0% 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
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/range-slider-field-for-contact-form-7/cf7-for-rangeslider.php
  • 4× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/range-slider-field-for-contact-form-7/main/resource/rsffcf7-load-js-css.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/range-slider-field-for-contact-form-7/main/resource/rsffcf7-language.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/range-slider-field-for-contact-form-7/main/resource/rsffcf7-installation-require.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/range-slider-field-for-contact-form-7/main/backend/rsffcf7-backend.php:290

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine on the user side

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Attributes that require attention:
  • Screenshots: These screenshots have no corresponding images in /assets: #1 (Range slider tab in contact form 7), #2 (Range slider General setting), #3 (Shortcode make like this in cf7), #4 (Front Range slider view)
  • Contributors: The plugin contributors field is not present
You can take inspiration from this readme.txt

range-slider-field-for-contact-form-7/cf7-for-rangeslider.php 92% from 13 tests

The main PHP script in "Range Slider Field for Contact Form 7" version 1.0 is automatically included on every request by WordPress
Please take the time to fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("range-slider-field-for-contact-form-7.php" instead of "cf7-for-rangeslider.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Everything looks great! No dangerous files found in this plugin1,399 lines of code in 13 files:
LanguageFilesBlank linesComment linesLines of code
CSS411046550
JavaScript4326104531
PHP5588318

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.18
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions11
▷ Named functions11100.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
1 PNG file occupies 0.04MB with 0.03MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/images/star.png39.75KB10.35KB▼ 73.95%