67% wp-subscribe-form

Code Review | Subscribe Forms - Beautiful Email Forms, Embedded Newsletter Forms & MailChimp Form

WordPress plugin Subscribe Forms - Beautiful Email Forms, Embedded Newsletter Forms & MailChimp Form scored 67% from 54 tests.

About plugin

  • Plugin page: wp-subscribe-form
  • Plugin version: 1.6
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.3
  • WordPress version: 6.3.1
  • First release: Dec 27, 2016
  • Latest release: Jul 27, 2023
  • Number of updates: 150
  • Update frequency: every 16.1 days
  • Top authors: galdub (66%)arrowplugins (25.33%)premiocommit (10%)

Code review

54 tests

User reviews

57 reviews

Install metrics

4,000+ active / 84,904 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.77MB] [CPU: ▲1.27ms] 75% from 4 tests

Server-side resources used by Subscribe Forms - Beautiful Email Forms, Embedded Newsletter Forms & MailChimp Form
Please have a look at the following items
  • CPU: The total CPU usage must kept under 500.00ms (currently 2,011.09ms on /wp-admin/edit.php?post_type=sfba_subscribe_form&page=sfba-recommended-plugins)
PageMemory (MB)CPU Time (ms)
Home /4.15 ▲0.6939.48 ▼3.87
Dashboard /wp-admin4.10 ▲0.7952.26 ▼0.41
Posts /wp-admin/edit.php4.21 ▲0.8567.57 ▲23.64
Add New Post /wp-admin/post-new.php6.70 ▲0.8294.16 ▲5.00
Media Library /wp-admin/upload.php4.02 ▲0.7940.27 ▲4.35
Upgrade To Pro /wp-admin/edit.php?post_type=sfba_subscribe_form&page=upgrade_to_pro4.0751.27
Add New /wp-admin/post-new.php?post_type=sfba_subscribe_form4.1063.63
Recommended Plugins /wp-admin/edit.php?post_type=sfba_subscribe_form&page=sfba-recommended-plugins4.452,011.09
All Subscribe Forms /wp-admin/edit.php?post_type=sfba_subscribe_form4.1054.81
Subscribers List /wp-admin/edit.php?post_type=sfba_subscribe_form&page=sfba_subscribers_list4.0549.23
Integrations /wp-admin/edit.php?post_type=sfba_subscribe_form&page=sfba_subscription_settings4.1457.26

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

Input-output and database impact of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 96 new files
Database: 2 new tables, 10 new options
New tables
wp_sfba_subscribers_lists
wp_sfba_subscription_lists
New WordPress options
widget_recent-posts
db_upgraded
widget_theysaidso_widget
subscribe-forms_show_review_box_after
widget_recent-comments
theysaidso_admin_options
subscribe-forms_show_affiliate_box_after
sfba_db_version
can_compress_scripts
subscribe_forms_redirect_status

Browser metrics Passed 4 tests

A check of browser resources used by Subscribe Forms - Beautiful Email Forms, Embedded Newsletter Forms & MailChimp Form
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,996 ▲26114.29 ▼0.086.68 ▲4.8842.02 ▼7.88
Dashboard /wp-admin2,284 ▲965.40 ▼0.50104.55 ▼10.2139.39 ▼5.58
Posts /wp-admin/edit.php2,169 ▲802.48 ▲0.4942.70 ▲7.1933.63 ▼1.90
Add New Post /wp-admin/post-new.php1,570 ▲3723.48 ▲0.54671.81 ▲15.9848.11 ▼3.94
Media Library /wp-admin/upload.php1,457 ▲724.67 ▲0.51102.84 ▲0.3343.21 ▼3.13
Upgrade To Pro /wp-admin/edit.php?post_type=sfba_subscribe_form&page=upgrade_to_pro1,7993.7871.86132.32
Add New /wp-admin/post-new.php?post_type=sfba_subscribe_form2,0784.2970.2898.68
Recommended Plugins /wp-admin/edit.php?post_type=sfba_subscribe_form&page=sfba-recommended-plugins1,4373.6750.5476.50
All Subscribe Forms /wp-admin/edit.php?post_type=sfba_subscribe_form1,4413.8849.1387.27
Subscribers List /wp-admin/edit.php?post_type=sfba_subscribe_form&page=sfba_subscribers_list1,1413.5844.0880.19
Integrations /wp-admin/edit.php?post_type=sfba_subscribe_form&page=sfba_subscription_settings1,9113.7147.2598.30

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • This plugin does not fully uninstall, leaving 2 tables in the database
    • wp_sfba_subscription_lists
    • wp_sfba_subscribers_lists
  • Zombie WordPress options detected upon uninstall: 10 options
    • can_compress_scripts
    • theysaidso_admin_options
    • subscribe-forms_show_affiliate_box_after
    • sfba_db_version
    • widget_recent-comments
    • widget_theysaidso_widget
    • db_upgraded
    • subscribe-forms_show_review_box_after
    • widget_recent-posts
    • subscribe_forms_redirect_status

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Good news, no errors were detected

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 take a closer look at the following
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/wp-subscribe-form/includes/upgrade-to-pro.php
  • 13× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_post_meta() in wp-content/plugins/wp-subscribe-form/forms/subscribeform1-settings.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_basename() in wp-content/plugins/wp-subscribe-form/index.php:16
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_post_meta() in wp-content/plugins/wp-subscribe-form/forms/subscribeform1-settings.php:2
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/wp-subscribe-form/includes/recommended-plugins.php on line 3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_post_meta() in wp-content/plugins/wp-subscribe-form/forms/subscribeform1-settings.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function admin_url() in wp-content/plugins/wp-subscribe-form/help.php:160
    • > PHP Warning
      require_once(ABSPATHwp-admin/includes/plugin-install.php): failed to open stream: No such file or directory in wp-content/plugins/wp-subscribe-form/includes/recommended-plugins.php on line 3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wp-subscribe-form/class-affiliate.php:9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_attr_e() in wp-content/plugins/wp-subscribe-form/includes/deactivate-form.php:119
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_post_meta() in wp-content/plugins/wp-subscribe-form/forms/subscribeform1-settings.php:2

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side

Optimizations

Plugin configuration 86% from 29 tests

readme.txt 94% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
Please fix the following attributes:
  • Tags: Too many tags (13 tag instead of maximum 10); only the first 5 tags are used in your directory listing
The official readme.txt might help

wp-subscribe-form/index.php 77% from 13 tests

The principal PHP file in "Subscribe Forms - Beautiful Email Forms, Embedded Newsletter Forms & MailChimp Form" v. 1.6 is loaded by WordPress automatically on each request
Please take the time to fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("wp-subscribe-form.php" instead of "index.php")
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug
  • Git Repository: Please remove the Git repository from this plugin

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 plugin12,269 lines of code in 56 files:
LanguageFilesBlank linesComment linesLines of code
PHP311,1452,60011,071
JavaScript87974552
SVG933540
YAML31068
CSS46233
JSON1005

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.27
Average class complexity16.40
▷ Minimum class complexity8.00
▷ Maximum class complexity21.00
Average method complexity1.55
▷ Minimum method complexity1.00
▷ Maximum method complexity19.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes5
▷ Abstract classes00.00%
▷ Concrete classes5100.00%
▷ Final classes00.00%
Methods138
▷ Static methods10.72%
▷ Public methods13396.38%
▷ Protected methods32.17%
▷ Private methods21.45%
Functions35
▷ Named functions35100.00%
▷ Anonymous functions00.00%
Constants10
▷ Global constants10100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
32 PNG files occupy 0.62MB with 0.12MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
includes/images/form5.png5.36KB6.09KB0.00%
includes/images/form4.png43.65KB46.84KB0.00%
includes/images/plus-price.png27.95KB14.13KB▼ 49.44%
includes/images/form12.png62.13KB66.53KB0.00%
images/plus-price.png27.95KB14.13KB▼ 49.44%