10% cta-widget-manager

Code Review | OrbitCarrot CTA Widget Manager

WordPress plugin OrbitCarrot CTA Widget Manager scored 10% from 54 tests.

About plugin

  • Plugin page: cta-widget-manager
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.4-4.8
  • WordPress version: 5.8.1
  • First release: Mar 4, 2015
  • Latest release: Aug 2, 2016
  • Number of updates: 28
  • Update frequency: every 29.7 days
  • Top authors: orbitcarrot (100%)

Code review

54 tests

User reviews

1 review

Install metrics

40+ active / 1,785 total downloads


Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The following installer errors require your attention
  • Install procedure had errors
    • > Deprecated in wp-content/plugins/cta-widget-manager/cta-widgetmanager.php+23
    Methods with the same name as their class will not be constructors in a future version of PHP; WidgetCta has a deprecated constructor

Server metrics [RAM: ▼1.83MB] [CPU: ▼190.19ms] Passed 4 tests

An overview of server-side resources used by OrbitCarrot CTA Widget Manager
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /1.80 ▼1.046.30 ▼31.03
Dashboard /wp-admin1.82 ▼1.245.33 ▼37.13
Posts /wp-admin/edit.php1.82 ▼1.298.67 ▼43.27
Add New Post /wp-admin/post-new.php1.82 ▼3.625.78 ▼649.33
Media Library /wp-admin/upload.php1.82 ▼1.186.25 ▼24.36

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

A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 15 new files
Database: no new tables, 1 new option
New WordPress options

Browser metrics Passed 4 tests

OrbitCarrot CTA Widget Manager: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,705 ▲10915.92 ▲0.039.29 ▲1.8347.59 ▲14.49
Dashboard /wp-admin2,973 ▲396.08 ▲0.14158.22 ▲5.09123.46 ▲6.62
Posts /wp-admin/edit.php2,739 ▼02.69 ▼0.0170.18 ▲0.3998.13 ▼5.56
Add New Post /wp-admin/post-new.php1,502 ▼9218.59 ▼0.24378.66 ▼17.93113.94 ▲1.24
Media Library /wp-admin/upload.php1,807 ▼05.02 ▼0.03148.97 ▼4.50126.32 ▲0.30

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
These items require your attention
  • The plugin did not uninstall gracefully
    • > Deprecated in wp-content/plugins/cta-widget-manager/cta-widgetmanager.php+23
    Methods with the same name as their class will not be constructors in a future version of PHP; WidgetCta has a deprecated constructor
  • Zombie WordPress options were found after uninstall: 1 option
    • widget_cta

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 50% 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
The following issues need your attention
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/cta-widget-manager/cta-widgetmanager.php:19

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


Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
These attributes need your attention:
  • Screenshots: Add images for these screenshots: #1 (Back-end: OrbitCarrot CTA Widget option.), #2 (Back-end: Once added to the Sidebar, you can enter the details of your CTA.), #3 (Front-end: Live CTA widget on a Wordpress website.)
  • Tags: You are using too many tags: 19 tag instead of maximum 10
Please take inspiration from this readme.txt

cta-widget-manager/cta-widgetmanager.php 92% from 13 tests

The primary PHP file in "OrbitCarrot CTA Widget Manager" version 1.1 is used by WordPress to initiate all plugin functionality
Please make the necessary changes and fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("cta-widget-manager.php" instead of "cta-widgetmanager.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
No dangerous file extensions were detected140 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.19
Average class complexity10.00
▷ Minimum class complexity10.00
▷ Maximum class complexity10.00
Average method complexity3.25
▷ Minimum method complexity1.00
▷ Maximum method complexity8.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
▷ Named functions2100.00%
▷ Anonymous functions00.00%
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.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
4 PNG files occupy 0.01MB with 0.01MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
css/img/redcta.png1.20KB0.10KB▼ 91.89%
css/img/redbutton.png2.72KB1.10KB▼ 59.35%
css/img/unstyled.png1.26KB0.11KB▼ 91.24%
css/img/bluebutton.png2.72KB1.03KB▼ 62.32%