Benchmarks
Plugin footprint 58% from 16 tests
Installer 0% from 1 test
🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
It is recommended to fix the following installer errors
- The plugin cannot be installed
- > Warning in wp-content/plugins/add-button-to-post/add_button_to_post.php+97
Use of undefined constant no - assumed 'no' (this will throw an Error in a future version of PHP)
Server metrics [RAM: ▼0.88MB] [CPU: ▼174.96ms] Passed 4 tests
Analyzing server-side resources used by Add Button To Post
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.87 ▲0.15 | 37.77 ▲16.89 |
Dashboard /wp-admin | 2.77 ▼0.29 | 23.70 ▼24.56 |
Posts /wp-admin/edit.php | 2.77 ▼0.34 | 27.46 ▼16.95 |
Add New Post /wp-admin/post-new.php | 2.77 ▼2.66 | 21.34 ▼642.08 |
Media Library /wp-admin/upload.php | 2.77 ▼0.23 | 20.11 ▼16.25 |
Add Button To Post /wp-admin/options-general.php?page=add-button-to-post/add_button_to_post.php | 2.77 | 20.20 |
Server storage [IO: ▲0.02MB] [DB: ▲0.00MB] Passed 3 tests
How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 9 new files
Database: no new tables, no new options
Browser metrics Passed 4 tests
Add Button To Post: an overview of browser usage
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,708 ▲112 | 15.76 ▲0.27 | 12.50 ▲2.90 | 47.90 ▲3.20 |
Dashboard /wp-admin | 2,975 ▲41 | 5.92 ▼0.03 | 138.63 ▼13.66 | 110.86 ▲3.73 |
Posts /wp-admin/edit.php | 2,744 ▲5 | 2.72 ▲0.01 | 64.31 ▼2.34 | 86.47 ▼9.89 |
Add New Post /wp-admin/post-new.php | 1,503 ▼180 | 18.54 ▲0.08 | 393.26 ▼9.47 | 105.09 ▼10.60 |
Media Library /wp-admin/upload.php | 1,812 ▲64 | 5.01 ▲0.00 | 159.22 ▲7.43 | 114.94 ▼0.00 |
Add Button To Post /wp-admin/options-general.php?page=add-button-to-post/add_button_to_post.php | 1,112 | 2.06 | 61.04 | 91.77 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
- Uninstall procedure had uncaught errors
- > User deprecated in wp-includes/functions.php+5495
has_cap was called with an argument that is deprecated since version 2.0.0! Usage of user levels is deprecated. Use capabilities instead.
Smoke tests 50% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These server-side errors were triggered
- 2 occurences, only the last one shown
- > GET request to /wp-admin/options-general.php?page=add-button-to-post/add_button_to_post.php
- > User deprecated in wp-includes/functions.php+5495
has_cap was called with an argument that is deprecated since version 2.0.0! Usage of user levels is deprecated. Use capabilities instead.
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
Please take a closer look at the following
- 2× PHP files trigger server-side errors or warnings when accessed directly:
- > PHP Fatal error
Uncaught Error: Call to undefined function settings_fields() in wp-content/plugins/add-button-to-post/add_button_to_post_setting.php:4
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/add-button-to-post/add_button_to_post.php:36
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were found
Optimizations
Plugin configuration 93% from 29 tests
readme.txt 94% from 16 tests
The readme.txt file uses markdown syntax to describe your plugin to the world
Attributes that require attention:
- Donate link: Please fix this invalid URI: ""
add-button-to-post/add_button_to_post.php 92% from 13 tests
This is the main PHP file of "Add Button To Post" version 1.1.6, 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:
- Main file name: It is recommended to name the main PHP file as the plugin slug ("add-button-to-post.php" instead of "add_button_to_post.php")
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
Success! There were no dangerous files found in this plugin272 lines of code in 5 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 3 | 31 | 26 | 172 |
CSS | 1 | 6 | 7 | 80 |
JavaScript | 1 | 1 | 2 | 20 |
PHP code Passed 2 tests
Analyzing cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.36 |
Average class complexity | 0.00 |
▷ Minimum class complexity | 0.00 |
▷ Maximum class complexity | 0.00 |
Average method complexity | 0.00 |
▷ Minimum method complexity | 0.00 |
▷ Maximum method complexity | 0.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 0 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 0 | 0.00% |
▷ Final classes | 0 | 0.00% |
Methods | 0 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 0 | 0.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 9 | |
▷ Named functions | 9 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 0 | |
▷ Global constants | 0 | 0.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
All PNG images should be compressed to minimize bandwidth usage for end users
3 compressed PNG files occupy 0.00MB
Potential savings
Compression of 3 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
images/twitter.png | 0.34KB | 0.33KB | ▼ 2.02% |
images/comment.png | 1.04KB | 1.02KB | ▼ 2.53% |
images/rss.png | 0.68KB | 0.73KB | 0.00% |