90% crazy-call-to-action-box

Code Review | Crazy Call To Action Box

WordPress plugin Crazy Call To Action Box scored90%from 54 tests.

About plugin

  • Plugin page: crazy-call-to-act...
  • Plugin version: 1.05
  • PHP version: 7.4.16
  • WordPress compatibility: 3.9.0-4.8
  • WordPress version: 6.3.1
  • First release: Sep 1, 2016
  • Latest release: May 19, 2017
  • Number of updates: 81
  • Update frequency: every 7.4 days
  • Top authors: hafizua (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

100+ active /2,989 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.01MB] [CPU: ▼9.75ms] Passed 4 tests

Server-side resources used by Crazy Call To Action Box
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0137.62 ▼4.15
Dashboard /wp-admin3.31 ▲0.0149.76 ▼1.46
Posts /wp-admin/edit.php3.37 ▲0.0149.75 ▼6.91
Add New Post /wp-admin/post-new.php5.90 ▲0.0189.58 ▼22.35
Media Library /wp-admin/upload.php3.24 ▲0.0135.17 ▼5.58

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

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

Browser metrics Passed 4 tests

This is an overview of browser requirements for Crazy Call To Action Box
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,830 ▲8414.20 ▲0.012.30 ▲0.5844.54 ▲4.80
Dashboard /wp-admin2,201 ▲215.63 ▲0.0389.95 ▲5.0842.28 ▼0.18
Posts /wp-admin/edit.php2,106 ▲62.03 ▲0.0840.14 ▲0.2835.93 ▲0.14
Add New Post /wp-admin/post-new.php1,532 ▼523.01 ▲4.41656.36 ▲26.4761.52 ▲1.43
Media Library /wp-admin/upload.php1,406 ▲64.22 ▲0.0395.14 ▼10.9244.55 ▲1.56

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-comments
    • widget_recent-posts
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options

Smoke tests Passed 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 Passed 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
No output text or server-side errors detected on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser errors were detected

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 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
10 plugin tags: amazon affiliate, call to action box, conversion rate optimization, affiliate link import, crazy call to action box...

crazy-call-to-action-box/cctabox.php 92% from 13 tests

Analyzing the main PHP file in "Crazy Call To Action Box" version 1.05
It is important to fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("crazy-call-to-action-box.php" instead of "cctabox.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 plugin758 lines of code in 8 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript2136334
SVG100288
PHP34720134
CSS2112

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.14
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%
Functions12
▷ Named functions12100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
css/ctab.png2.04KB1.57KB▼ 23.16%