94% animated-buttons-with-css3

Code Review | Animated Buttons with CSS3

WordPress plugin Animated Buttons with CSS3 scored 94% from 54 tests.

About plugin

  • Plugin page: animated-buttons-...
  • Plugin version: 0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.1-3.4
  • WordPress version: 5.9.2
  • First release: Sep 27, 2012
  • Latest release: Sep 28, 2012
  • Number of updates: 3
  • Update frequency: every 0.3 days
  • Top authors: jodacame (100%)

Code review

54 tests

User reviews

1 review

Install metrics

80+ active / 4,703 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
This plugin's installer ran successfully

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

Server-side resources used by Animated Buttons with CSS3
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0256.24 ▲3.94
Dashboard /wp-admin3.42 ▲0.0133.34 ▼0.41
Posts /wp-admin/edit.php3.65 ▲0.0135.58 ▼2.84
Add New Post /wp-admin/post-new.php6.90 ▼0.0793.90 ▼1,174.65
Media Library /wp-admin/upload.php3.31 ▲0.0122.93 ▼7.49

Server storage [IO: ▲0.13MB] [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: 14 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

This is an overview of browser requirements for Animated Buttons with CSS3
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,765 ▲2316.21 ▲0.396.25 ▲0.502.15 ▲0.03
Dashboard /wp-admin2,888 ▲346.03 ▼0.18114.39 ▼16.01154.99 ▼3.87
Posts /wp-admin/edit.php2,694 ▼03.23 ▼0.0061.56 ▼0.54140.94 ▼1.73
Add New Post /wp-admin/post-new.php1,668 ▼8418.39 ▼3.23403.14 ▼47.09156.40 ▲4.96
Media Library /wp-admin/upload.php1,698 ▼05.52 ▼0.00138.25 ▲1.29184.53 ▼5.78

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The plugin uninstalled completely, with no zombie files or tables

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Everything seems fine, however this is by no means an exhaustive test

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
The following issues need your attention
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/animated-buttons-with-css3/animated-buttons-with-css3.php:27

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
These attributes need to be fixed:
  • Screenshots: These screenshots have no corresponding images in /assets: #1 (Screenshot Post), #2 (Screenshot Panel)
Please take inspiration from this readme.txt

animated-buttons-with-css3/animated-buttons-with-css3.php 92% from 13 tests

This is the main PHP file of "Animated Buttons with CSS3" version 0.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
The following require your attention:
  • Description: Please don't use more than 140 characters for the plugin description (currently 151 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Everything looks great! No dangerous files found in this plugin212 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
CSS14922101
JavaScript44468
PHP191043

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.09
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%
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

All PNG images should be compressed to minimize bandwidth usage for end users
7 PNG files occupy 0.12MB with 0.05MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
js/BGreen.png0.42KB0.34KB▼ 18.10%
button_bg.png15.70KB7.88KB▼ 49.77%
screenshot-1.png85.20KB29.13KB▼ 65.82%
screenshot-2.png16.79KB7.82KB▼ 53.40%
js/BBlue.png0.38KB0.32KB▼ 17.56%