67% better-forms

Code Review | Better Forms

WordPress plugin Better Forms scored 67% from 54 tests.

About plugin

  • Plugin page: better-forms
  • Plugin version: 1.1.3
  • PHP version: 7.4.16
  • WordPress compatibility: 3.1-4.3
  • WordPress version: 6.3.1
  • First release: Jun 23, 2013
  • Latest release: Aug 8, 2015
  • Number of updates: 9
  • Update frequency: every 86.2 days
  • Top authors: Synved (100%)

Code review

54 tests

User reviews

1 review

Install metrics

40+ active / 6,119 total downloads

Benchmarks

Plugin footprint 64% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲1.60MB] [CPU: ▲615.41ms] 50% from 4 tests

Analyzing server-side resources used by Better Forms
Please take the time to fix the following items
  • CPU: You should keep total CPU usage under 500.00ms (currently 880.78ms on /wp-admin/options-general.php?page=synved_form_settings)
  • Extra CPU: Extra CPU usage must be kept under 200.00ms (currently 615.41ms on /wp-admin/options-general.php?page=synved_form_settings)
PageMemory (MB)CPU Time (ms)
Home /3.92 ▲0.4647.02 ▲0.52
Dashboard /wp-admin6.16 ▲2.86874.79 ▲803.81
Posts /wp-admin/edit.php6.16 ▲2.81766.46 ▲713.60
Add New Post /wp-admin/post-new.php6.16 ▲0.281,032.86 ▲943.69
Media Library /wp-admin/upload.php6.16 ▲2.931,089.45 ▲1,054.39
Better Forms /wp-admin/options-general.php?page=synved_form_settings6.16880.78

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

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 63 new files
Database: no new tables, 7 new options
New WordPress options
theysaidso_admin_options
widget_recent-posts
widget_theysaidso_widget
widget_recent-comments
db_upgraded
synved_connect_install_date
can_compress_scripts

Browser metrics Passed 4 tests

Better Forms: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,946 ▲12114.42 ▲0.886.09 ▲3.9635.02 ▼9.57
Dashboard /wp-admin2,254 ▲455.55 ▼0.31124.79 ▲11.5245.27 ▲1.56
Posts /wp-admin/edit.php2,080 ▼122.41 ▲0.4154.87 ▲18.4833.07 ▼5.08
Add New Post /wp-admin/post-new.php1,517 ▲323.29 ▲5.80689.09 ▲1.6038.21 ▼13.64
Media Library /wp-admin/upload.php1,393 ▲54.50 ▲0.18112.28 ▲11.0548.69 ▲2.09
Better Forms /wp-admin/options-general.php?page=synved_form_settings9042.2645.9447.07

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
You still need to fix the following
  • The plugin did not uninstall gracefully
    • > Deprecated in wp-content/plugins/better-forms/synved-option/synved-option-page.php+146
    Function create_function() is deprecated
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • synved_connect_install_date
    • db_upgraded
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments
    • widget_recent-posts

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
These server-side errors were triggered
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=synved_form_settings
    • > Deprecated in wp-content/plugins/better-forms/synved-option/synved-option.php+601
    Function create_function() is deprecated

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
  • 6× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_admin() in wp-content/plugins/better-forms/synved-connect/synved-connect.php:212
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_admin() in wp-content/plugins/better-forms/synved-option/addons/option-type-addon/option-type-addon.php:188
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/better-forms/synved-option/synved-option.php:1124
    • > PHP Fatal error
      Uncaught Error: Call to undefined function synved_option_callback() in wp-content/plugins/better-forms/synved-form/synved-form-setup.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function synved_option_callback() in wp-content/plugins/better-forms/synved-form/synved-form-setup.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_admin() in wp-content/plugins/better-forms/synved-connect/synved-connect.php:212

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
Please fix the following attributes:
  • Tags: Too many tags (27 tag instead of maximum 10); only the first 5 tags are used in your directory listing
  • Screenshots: These screenshots require images: #1 (A demo of how form elements will look), #2 (A demo of how form elements will look on focus), #3 (An example of all form elements together)
Please take inspiration from this readme.txt

better-forms/better-forms.php Passed 13 tests

The main file in "Better Forms" v. 1.1.3 serves as a complement to information provided in readme.txt and as the entry point to the plugin
134 characters long description:
Lightweight plugin that just simply makes the forms on your WordPress site look better, more professional and reliable across browsers

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
There were no executable files found in this plugin4,647 lines of code in 32 files:
LanguageFilesBlank linesComment linesLines of code
PHP218871413,322
CSS67149823
JavaScript511080502

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.49
Average class complexity7.50
▷ Minimum class complexity1.00
▷ Maximum class complexity14.00
Average method complexity4.25
▷ Minimum method complexity1.00
▷ Maximum method complexity10.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods375.00%
▷ Protected methods125.00%
▷ Private methods00.00%
Functions160
▷ Named functions160100.00%
▷ Anonymous functions00.00%
Constants17
▷ Global constants1376.47%
▷ Class constants423.53%
▷ Public constants4100.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
21 PNG files occupy 0.04MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
synved-option/jqueryUI/css/snvdopt/images/ui-bg_glass_75_e6e6e6_1x400.png0.11KB0.14KB0.00%
synved-option/jqueryUI/css/snvdopt/images/ui-bg_flat_75_ffffff_40x100.png0.17KB0.08KB▼ 51.12%
synved-option/jqueryUI/css/snvdopt/images/ui-icons_2e83ff_256x240.png5.23KB4.11KB▼ 21.49%
synved-option/farbtastic/wheel.png11.46KB6.53KB▼ 43.01%
synved-connect/image/small/rss.png0.82KB0.71KB▼ 12.57%