68% squeeze-page-toolkit

Code Review | Squeeze Page Toolkit for WordPress

WordPress plugin Squeeze Page Toolkit for WordPress scored68%from 54 tests.

About plugin

  • Plugin page: squeeze-page-toolkit
  • Plugin version: 1.20
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.6
  • WordPress version: 6.3.1
  • First release: Apr 18, 2014
  • Latest release: Dec 17, 2020
  • Number of updates: 32
  • Update frequency: every 76.3 days
  • Top authors: DanHarrison (100%)

Code review

54 tests

User reviews

1 review

Install metrics

40+ active /10,459 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

Server metrics [RAM: ▲0.41MB] [CPU: ▼2.12ms] 75% from 4 tests

An overview of server-side resources used by Squeeze Page Toolkit for WordPress
Please fix the following
  • CPU: Try to keep total CPU usage under 500.00ms (currently 577.95ms on /wp-admin/edit.php?post_type=squeeze_page&page=SPTK_showPage_Settings)
PageMemory (MB)CPU Time (ms)
Home /13.89 ▲10.392,032,389.63 ▲2,032,346.59
Dashboard /wp-admin3.78 ▲0.4454.69 ▼0.80
Posts /wp-admin/edit.php3.83 ▲0.4453.78 ▼3.43
Add New Post /wp-admin/post-new.php6.31 ▲0.3892.58 ▼7.06
Media Library /wp-admin/upload.php3.64 ▲0.3741.66 ▲2.80
Squeeze Pages /wp-admin/edit.php?post_type=squeeze_page3.7540.56
Settings /wp-admin/edit.php?post_type=squeeze_page&page=SPTK_showPage_Settings3.69577.95
Add New /wp-admin/post-new.php?post_type=squeeze_page3.76484.23

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

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 12 new files
Database: 1 new table, 7 new options
New tables
wp_sptk_page_cache
New WordPress options
can_compress_scripts
theysaidso_admin_options
db_upgraded
SPTK_Version
widget_recent-comments
widget_theysaidso_widget
widget_recent-posts

Browser metrics Passed 4 tests

A check of browser resources used by Squeeze Page Toolkit for WordPress
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,866 ▲10514.17 ▼0.191.82 ▲0.1041.22 ▼4.96
Dashboard /wp-admin2,272 ▲985.60 ▲0.0488.66 ▼8.3944.96 ▲2.96
Posts /wp-admin/edit.php2,174 ▲712.03 ▼0.0140.20 ▲1.9539.05 ▲3.71
Add New Post /wp-admin/post-new.php1,589 ▲5823.19 ▲0.17695.86 ▲39.0254.17 ▲3.23
Media Library /wp-admin/upload.php1,477 ▲804.31 ▲0.09106.04 ▲3.0645.93 ▲0.89
Squeeze Pages /wp-admin/edit.php?post_type=squeeze_page1,1351.9833.0332.29
Settings /wp-admin/edit.php?post_type=squeeze_page&page=SPTK_showPage_Settings9971.9326.3126.48
Add New /wp-admin/post-new.php?post_type=squeeze_page1,5562.5049.9261.52

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • This plugin does not fully uninstall, leaving 1 table in the database
    • wp_sptk_page_cache
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-comments
    • widget_recent-posts
    • db_upgraded
    • can_compress_scripts
    • SPTK_Version

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
Almost there, just fix the following server-side errors
  • 34 occurences, only the last one shown
    • > GET request to /wp-admin/post-new.php?post_type=squeeze_page
    • > POST request to /wp-cron.php?doing_wp_cron=1697551793.8827230930328369140625
    • > Warning in wp-content/plugins/easy-age-verifier/lib/extras/wpApi.php+48
    file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known
  • 34 occurences, only the last one shown
    • > GET request to /wp-admin/post-new.php?post_type=squeeze_page
    • > POST request to /wp-cron.php?doing_wp_cron=1697551793.8827230930328369140625
    • > Warning in wp-content/plugins/easy-age-verifier/lib/extras/wpApi.php+48
    file_get_contents(http://www.fillyourtaproom.com/wp-json/wp/v2/posts?per_page=10): failed to open stream: php_network_getaddresses: getaddrinfo failed: Name or service not known

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following items
  • 4× 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/squeeze-page-toolkit/squeeze-page-toolkit.php:35
    • > PHP Fatal error
      Uncaught Error: Call to a member function getMessage() on null in wp-content/plugins/squeeze-page-toolkit/api/index.php:32
    • > PHP Notice
      Trying to get property 'prefix' of non-object in wp-content/plugins/squeeze-page-toolkit/lib/db.inc.php on line 21
    • > PHP Notice
      Trying to get property 'prefix' of non-object in wp-content/plugins/squeeze-page-toolkit/lib/db.inc.php on line 21

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 Passed 29 tests

readme.txt Passed 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
4 plugin tags: landing pages, squeeze pages, squeeze page toolkit, opt-in boxes

squeeze-page-toolkit/squeeze-page-toolkit.php Passed 13 tests

The primary PHP file in "Squeeze Page Toolkit for WordPress" version 1.20 is used by WordPress to initiate all plugin functionality
130 characters long description:
The official plugin for the Squeeze Page Toolkit for WordPress, allowing you to show your squeeze pages on your WordPress website.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
There were no executable files found in this plugin2,407 lines of code in 11 files:
LanguageFilesBlank linesComment linesLines of code
PHP108741,7902,378
CSS16129

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.46
Average class complexity45.00
▷ Minimum class complexity1.00
▷ Maximum class complexity160.00
Average method complexity4.28
▷ Minimum method complexity1.00
▷ Maximum method complexity60.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods94
▷ Static methods11.06%
▷ Public methods8186.17%
▷ Protected methods1111.70%
▷ Private methods22.13%
Functions42
▷ Named functions42100.00%
▷ Anonymous functions00.00%
Constants7
▷ Global constants7100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
There were not PNG files found in your plugin