10% cta-button-styler

Code Review | CTA Button Styles

WordPress plugin CTA Button Styles scored10%from 54 tests.

About plugin

  • Plugin page: cta-button-styler
  • Plugin version: 1.1.3
  • PHP compatiblity: 7.3+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.4-6.4.1
  • WordPress version: 6.3.1
  • First release: Jul 26, 2016
  • Latest release: Nov 20, 2023
  • Number of updates: 81
  • Update frequency: every 33.0 days
  • Top authors: creatorseo (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

500+ active /9,998 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
These installer errors require your attention
  • Install procedure had errors
    • > User notice in wp-includes/functions.php+5905
    Function register_uninstall_hook was called incorrectly. Only a static class method or function can be used in an uninstall hook. Please see Debugging in WordPress for more information. (This message was added in version 3.1.0.)

Server metrics [RAM: ▼1.74MB] [CPU: ▼55.60ms] Passed 4 tests

Server-side resources used by CTA Button Styles
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.59 ▲0.1336.99 ▼4.71
Dashboard /wp-admin2.21 ▼1.137.59 ▼54.34
Posts /wp-admin/edit.php2.21 ▼1.147.34 ▼46.71
Add New Post /wp-admin/post-new.php2.21 ▼3.677.08 ▼93.21
Media Library /wp-admin/upload.php2.21 ▼1.026.91 ▼28.14
CTA Button Styler /wp-admin/themes.php?page=cta_button_styler2.227.05

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 8 new files
Database: no new tables, 10 new options
New WordPress options
widget_recent-comments
theysaidso_admin_options
widget_recent-posts
cta_button_hover_options
db_upgraded
widget_theysaidso_widget
cta_button_name
can_compress_scripts
cta_button_effects
cta_button_options

Browser metrics Passed 4 tests

An overview of browser requirements for CTA Button Styles
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,942 ▲19513.63 ▼0.715.68 ▲4.2138.72 ▼3.27
Dashboard /wp-admin2,228 ▲515.95 ▲0.3597.07 ▲1.1942.64 ▼2.42
Posts /wp-admin/edit.php2,135 ▲382.35 ▲0.3839.77 ▼0.3234.89 ▲0.86
Add New Post /wp-admin/post-new.php1,552 ▲2623.43 ▲0.28670.18 ▲37.4437.97 ▼15.45
Media Library /wp-admin/upload.php1,427 ▲274.50 ▲0.3399.17 ▲1.4342.45 ▲3.50
CTA Button Styler /wp-admin/themes.php?page=cta_button_styler2,3303.2980.3132.55

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • This plugin did not uninstall without warnings or errors
    • > User notice in wp-includes/functions.php+5905
    Function register_uninstall_hook was called incorrectly. Only a static class method or function can be used in an uninstall hook. Please see Debugging in WordPress for more information. (This message was added in version 3.1.0.)
  • The uninstall procedure has failed, leaving 10 options in the database
    • cta_button_effects
    • cta_button_hover_options
    • widget_recent-posts
    • cta_button_name
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • cta_button_options
    • db_upgraded
    • can_compress_scripts
    • widget_recent-comments

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
These server-side errors were triggered
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/themes.php?page=cta_button_styler
    • > POST request to /wp-admin/admin-ajax.php
    • > User notice in wp-includes/functions.php+5905
    Function register_uninstall_hook was called incorrectly. Only a static class method or function can be used in an uninstall hook. Please see Debugging in WordPress for more information. (This message was added in version 3.1.0.)

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
The following issues need your attention
  • 2× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/cta-button-styler/css/cta-button-style.php:6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/cta-button-styler/inc/ctabtn-shortcodes.php:53

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

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
9 plugin tags: call to action, styling, plugin, click through rate, button...

cta-button-styler/cta-button-styler.php Passed 13 tests

The primary PHP file in "CTA Button Styles" version 1.1.3 is used by WordPress to initiate all plugin functionality
85 characters long description:
Style your Call To Action (CTA) links and buttons to improve your click-through rates

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 plugin563 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP551113451
JavaScript181788
CSS18124

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.25
Average class complexity15.00
▷ Minimum class complexity15.00
▷ Maximum class complexity15.00
Average method complexity2.40
▷ Minimum method complexity1.00
▷ Maximum method complexity8.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods10
▷ Static methods00.00%
▷ Public methods10100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions5
▷ Named functions5100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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