77% zigaform-form-builder-lite

Code Review | Zigaform - Form Builder lite

WordPress plugin Zigaform - Form Builder lite scored77%from 54 tests.

About plugin

  • Plugin page: zigaform-form-bui...
  • Plugin version: 5.7.6
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.3
  • WordPress version: 6.3.1
  • First release: Sep 16, 2016
  • Latest release: Sep 24, 2023
  • Number of updates: 144
  • Update frequency: every 17.8 days
  • Top authors: softdiscover (100%)

Code review

54 tests

User reviews

12 reviews

Install metrics

100+ active /15,692 total downloads

Benchmarks

Plugin footprint 82% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲1.66MB] [CPU: ▲6.85ms] Passed 4 tests

An overview of server-side resources used by Zigaform - Form Builder lite
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /4.43 ▲0.9753.69 ▲12.31
Dashboard /wp-admin5.20 ▲1.9064.20 ▲10.68
Posts /wp-admin/edit.php5.25 ▲1.8964.90 ▲9.20
Add New Post /wp-admin/post-new.php7.79 ▲1.91105.17 ▼4.79
Media Library /wp-admin/upload.php5.12 ▲1.8968.23 ▲28.32
About /wp-admin/admin.php?page=zigaform-builder-about5.1551.18
Forms /wp-admin/admin.php?page=zgfm_form_builder5.9050.43
Help /wp-admin/admin.php?page=zigaform-builder-help5.1451.68
Go Pro! /wp-admin/admin.php?page=zigaform-builder-gopro5.1647.78

Server storage [IO: ▲34.79MB] [DB: ▲0.02MB] 33% from 3 tests

Filesystem and database footprint
It is recommended to fix the following issues
  • There were 1 file (4.00KB) illegally modified outside of "wp-content/plugins/zigaform-form-builder-lite/" and "wp-content/uploads/"
    • (new file) wp-content/mgd_mirror/mgd_maximinodotpy-gitdown-test-repository
  • Try to limit filesystem usage to 25MB (currently using 34.79MB)
Filesystem: 1,599 new files
Database: 9 new tables, 10 new options
New tables
wp_uiform_fields
wp_uiform_form_log
wp_uiform_addon
wp_uiform_addon_details_log
wp_uiform_fields_type
wp_uiform_addon_details
wp_uiform_form_records
wp_uiform_form
wp_uiform_settings
New WordPress options
db_upgraded
widget_recent-posts
zgfm_b_modalmode
zigaform_f_notice_1
zgfm_b_activated
widget_theysaidso_widget
uifmfbuild_version
theysaidso_admin_options
widget_recent-comments
can_compress_scripts

Browser metrics Passed 4 tests

Checking browser requirements for Zigaform - Form Builder lite
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,030 ▲26914.53 ▼0.086.72 ▲4.9437.67 ▼2.61
Dashboard /wp-admin2,313 ▲1075.62 ▲0.76117.17 ▲7.9199.36 ▲54.77
Posts /wp-admin/edit.php2,227 ▲1242.86 ▲0.8844.78 ▲1.5670.10 ▲31.13
Add New Post /wp-admin/post-new.php1,780 ▲23423.54 ▲0.42804.60 ▲166.6430.75 ▼22.52
Media Library /wp-admin/upload.php1,505 ▲1085.18 ▲0.95123.43 ▲13.7399.29 ▲53.56
About /wp-admin/admin.php?page=zigaform-builder-about1,8695.6498.31139.42
Forms /wp-admin/admin.php?page=zgfm_form_builder1,7475.0378.6462.98
Help /wp-admin/admin.php?page=zigaform-builder-help1,1584.5251.8949.70
Go Pro! /wp-admin/admin.php?page=zigaform-builder-gopro1,3824.4650.6260.06

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • Zombie WordPress options detected upon uninstall: 9 options
    • db_upgraded
    • widget_recent-posts
    • widget_theysaidso_widget
    • zigaform_f_notice_1
    • zgfm_b_modalmode
    • zgfm_b_activated
    • widget_recent-comments
    • can_compress_scripts
    • theysaidso_admin_options

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
Good news, no errors were detected

SRP 0% 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
Please fix the following
  • 288× PHP files perform the action of outputting non-empty strings when accessed directly (only 10 are shown):
    • > /wp-content/plugins/zigaform-form-builder-lite/modules/formbuilder/views/forms/form_show_shortcodes.php
    • > /wp-content/plugins/zigaform-form-builder-lite/modules/formbuilder/views/fields/render_css_front/type_dyncheckbox.php
    • > /wp-content/plugins/zigaform-form-builder-lite/modules/formbuilder/views/fields/render_css_front/type_heading.php
    • > /wp-content/plugins/zigaform-form-builder-lite/modules/formbuilder/views/fields/render_css_front/block_main.php
    • > /wp-content/plugins/zigaform-form-builder-lite/modules/formbuilder/views/fields/render_front/type_range.php
    • > /wp-content/plugins/zigaform-form-builder-lite/modules/default/controllers/backend.php
    • > /wp-content/plugins/zigaform-form-builder-lite/modules/formbuilder/views/fields/templates/prevpanel_quickopts3.php
    • > /wp-content/plugins/zigaform-form-builder-lite/modules/formbuilder/views/forms/formhtml_css_wizard.php
    • > /wp-content/plugins/zigaform-form-builder-lite/modules/formbuilder/views/forms/list_forms.php
    • > /wp-content/plugins/zigaform-form-builder-lite/modules/formbuilder/views/fields/templates/prevpanel_switch.php
  • 30× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Gettext\\Languages\\Exporter\\Exporter' not found in wp-content/plugins/zigaform-form-builder-lite/modules/addon_mgtranslate/vendor/gettext/languages/src/Exporter/Po.php:7
    • > PHP Fatal error
      Uncaught Error: Class 'Gettext\\Languages\\Exporter\\Html' not found in wp-content/plugins/zigaform-form-builder-lite/modules/addon_mgtranslate/vendor/gettext/languages/src/Exporter/Docs.php:5
    • > PHP Fatal error
      Uncaught Error: Interface 'ReCaptcha\\RequestMethod' not found in wp-content/plugins/zigaform-form-builder-lite/libraries/recaptcha/1.3.0/src/ReCaptcha/RequestMethod/SocketPost.php:46
    • > PHP Fatal error
      Uncaught Error: Class 'Gettext\\Languages\\Exporter\\Exporter' not found in wp-content/plugins/zigaform-form-builder-lite/modules/addon_mgtranslate/vendor/gettext/languages/src/Exporter/Html.php:5
    • > PHP Fatal error
      Composer detected issues in your platform: Your Composer dependencies require a PHP version ">= 8.0.0". You are running 7.4.16. in wp-content/plugins/zigaform-form-builder-lite/libraries/recaptcha/1.3.0/vendor/composer/platform_check.php on line 24
    • > PHP Fatal error
      Uncaught Error: Class 'Gettext\\Languages\\Exporter\\Json' not found in wp-content/plugins/zigaform-form-builder-lite/modules/addon_mgtranslate/vendor/gettext/languages/src/Exporter/Prettyjson.php:7
    • > PHP Notice
      Undefined variable: idform in wp-content/plugins/zigaform-form-builder-lite/modules/formbuilder/views/forms/formhtml_css_form.php on line 17
    • > PHP Fatal error
      Uncaught Error: Interface 'ReCaptcha\\RequestMethod' not found in wp-content/plugins/zigaform-form-builder-lite/libraries/recaptcha2/ReCaptcha/RequestMethod/CurlPost.php:38
    • > PHP Fatal error
      Uncaught Error: Interface 'ReCaptcha\\RequestMethod' not found in wp-content/plugins/zigaform-form-builder-lite/libraries/recaptcha2/ReCaptcha/RequestMethod/Post.php:36
    • > PHP Fatal error
      Uncaught Error: Class 'Gettext\\Generator\\Generator' not found in wp-content/plugins/zigaform-form-builder-lite/modules/addon_mgtranslate/vendor/gettext/gettext/src/Generator/MoGenerator.php:9

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser issues were found

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% 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
Please fix the following attributes:
  • Tags: Too many tags (15 tag instead of maximum 10); only the first 5 tags are used in your directory listing
The official readme.txt might help

zigaform-form-builder-lite/zigaform-form-builder-lite.php Passed 13 tests

The entry point to "Zigaform - Form Builder lite" version 5.7.6 is a PHP file that has certain tags in its header comment area
89 characters long description:
The ZigaForm WordPress form builder is the ultimate form creation solution for WordPress.

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Good job! No executable or dangerous file extensions detected267,596 lines of code in 715 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript16912,15911,968105,446
CSS838,9711,15690,375
PHP3706,76810,23344,718
PO File167,2727,30416,203
SVG9003,828
JSON26002,380
Sass1434341,768
LESS1434441,758
HTML81200675
Markdown51920439
YAML1206

PHP code 50% from 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Please fix the following
  • Method cyclomatic complexity should be reduced to less than 100 (currently 117)
Cyclomatic complexity
Average complexity per logical line of code0.34
Average class complexity30.27
▷ Minimum class complexity1.00
▷ Maximum class complexity391.00
Average method complexity3.55
▷ Minimum method complexity1.00
▷ Maximum method complexity117.00
Code structure
Namespaces13
Interfaces8
Traits1
Classes106
▷ Abstract classes76.60%
▷ Concrete classes9993.40%
▷ Final classes77.07%
Methods1,343
▷ Static methods14110.50%
▷ Public methods98473.27%
▷ Protected methods32324.05%
▷ Private methods362.68%
Functions24
▷ Named functions1250.00%
▷ Anonymous functions1250.00%
Constants178
▷ Global constants2413.48%
▷ Class constants15486.52%
▷ Public constants15198.05%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
746 PNG files occupy 1.81MB with 0.90MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
libraries/styles-font-menu/styles-fonts/png/arbutusslab-regular.png2.36KB1.25KB▼ 47.27%
libraries/styles-font-menu/styles-fonts/png/alice-regular.png1.26KB0.60KB▼ 52.59%
libraries/styles-font-menu/styles-fonts/png/spicyrice-regular.png2.43KB1.18KB▼ 51.40%
libraries/styles-font-menu/styles-fonts/png/ruluko-regular.png1.29KB0.64KB▼ 50.45%
libraries/styles-font-menu/styles-fonts/png/rochester-regular.png2.16KB1.14KB▼ 47.01%