Benchmarks
Plugin footprint 65% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully
Server metrics [RAM: ▲0.08MB] [CPU: ▼9.42ms] Passed 4 tests
An overview of server-side resources used by Token Manager
Server-side resource usage in normal parameters
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.51 ▲0.05 | 45.04 ▼8.85 |
Dashboard /wp-admin | 3.39 ▲0.09 | 47.51 ▼2.37 |
Posts /wp-admin/edit.php | 3.43 ▲0.07 | 45.60 ▼1.65 |
Add New Post /wp-admin/post-new.php | 6.08 ▲0.20 | 76.82 ▼24.79 |
Media Library /wp-admin/upload.php | 3.33 ▲0.10 | 39.36 ▲3.33 |
Backup System /wp-admin/admin.php?page=tokenmanagerpro | 3.33 | 37.32 |
Token Types /wp-admin/admin.php?page=tokenmanagertypes | 3.42 | 38.38 |
Information /wp-admin/admin.php?page=tokenmanagerinfo | 3.29 | 32.77 |
/wp-admin/admin.php?page=tokenmanagerjson | 3.41 | 34.56 |
Add New Token /wp-admin/admin.php?page=tokenmanageradd | 3.36 | 37.41 |
Tokens /wp-admin/admin.php?page=tokenmanager | 3.50 | 45.61 |
Settings /wp-admin/admin.php?page=tokenmanagersettings | 3.33 | 44.67 |
Add New Type /wp-admin/admin.php?page=tokenmanageraddtype | 3.32 | 36.55 |
/wp-admin/admin.php?page=tokenmanagertypeedit | 3.33 | 34.23 |
/wp-admin/admin.php?page=tokenmanageredit | 3.36 | 35.58 |
Server storage [IO: ▲0.87MB] [DB: ▲0.01MB] Passed 3 tests
Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 83 new files
Database: 5 new tables, 7 new options
New tables |
---|
wp_tokenmanagerpages |
wp_tokenmanagerversions |
wp_tokenmanagertypesversions |
wp_tokenmanager |
wp_tokenmanagertypes |
New WordPress options |
---|
theysaidso_admin_options |
widget_theysaidso_widget |
widget_recent-comments |
widget_recent-posts |
db_upgraded |
can_compress_scripts |
tokenmanager_db_version |
Browser metrics Passed 4 tests
A check of browser resources used by Token Manager
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,835 ▲74 | 14.27 ▼0.32 | 2.06 ▼0.48 | 47.30 ▼16.65 |
Dashboard /wp-admin | 2,241 ▲64 | 5.74 ▲0.05 | 90.11 ▼29.39 | 77.95 ▲21.19 |
Posts /wp-admin/edit.php | 2,146 ▲46 | 1.98 ▼0.01 | 33.69 ▼7.35 | 34.19 ▼3.96 |
Add New Post /wp-admin/post-new.php | 1,579 ▲42 | 23.42 ▲5.26 | 780.75 ▲142.47 | 54.48 ▼17.48 |
Media Library /wp-admin/upload.php | 1,449 ▲49 | 4.12 ▲0.01 | 99.92 ▼16.67 | 69.02 ▲23.44 |
Backup System /wp-admin/admin.php?page=tokenmanagerpro | 1,096 | 2.18 | 25.34 | 31.76 |
Token Types /wp-admin/admin.php?page=tokenmanagertypes | 940 | 1.99 | 24.91 | 29.89 |
Information /wp-admin/admin.php?page=tokenmanagerinfo | 976 | 2.11 | 25.66 | 30.30 |
/wp-admin/admin.php?page=tokenmanagerjson | 804 | 1.97 | 23.69 | 25.03 |
Add New Token /wp-admin/admin.php?page=tokenmanageradd | 2,025 | 2.20 | 33.82 | 39.69 |
Tokens /wp-admin/admin.php?page=tokenmanager | 1,041 | 2.03 | 24.01 | 27.28 |
Settings /wp-admin/admin.php?page=tokenmanagersettings | 969 | 2.17 | 25.81 | 24.90 |
Add New Type /wp-admin/admin.php?page=tokenmanageraddtype | 905 | 2.12 | 26.15 | 25.47 |
/wp-admin/admin.php?page=tokenmanagertypeedit | 887 | 2.13 | 24.89 | 28.25 |
/wp-admin/admin.php?page=tokenmanageredit | 2,021 | 2.21 | 36.05 | 38.48 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.01MB] 50% from 4 tests
🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
It is recommended to fix the following
- The plugin did not uninstall successfully, leaving 5 tables in the database
- wp_tokenmanagerpages
- wp_tokenmanagertypesversions
- wp_tokenmanagertypes
- wp_tokenmanager
- wp_tokenmanagerversions
- The uninstall procedure has failed, leaving 7 options in the database
- can_compress_scripts
- widget_recent-posts
- widget_recent-comments
- widget_theysaidso_widget
- db_upgraded
- tokenmanager_db_version
- theysaidso_admin_options
Smoke tests 25% 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 errors were triggered by the plugin
- 2 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=tokenmanageredit
- > Notice in wp-content/plugins/token-manager/tokenedit.php+194
Undefined index: tid
SRP 0% 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× GET requests to PHP files return non-empty strings:
- > /wp-content/plugins/token-manager/json.php
- 11× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/token-manager/info.php:1
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/token-manager/types.php:24
- > PHP Fatal error
Uncaught Error: Call to undefined function get_option() in wp-content/plugins/token-manager/token-manager.php:33
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/token-manager/tokenadd.php:23
- > PHP Fatal error
Uncaught Error: Call to undefined function get_option() in wp-content/plugins/token-manager/settings.php:65
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/token-manager/typeedit.php:22
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/token-manager/typeadd.php:20
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/token-manager/sidebar.php:12
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/token-manager/tokens.php:25
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/token-manager/tokenedit.php:23
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration 93% from 29 tests
readme.txt 88% from 16 tests
The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
These attributes need to be fixed:
- Screenshots: These screenshots do not have images: #1 (Here is a screen shot of adding a token that creates a copyright.), #2 (Here is what the Token Manager looks like.), #3 (This screen shot shows how to assign tokens to pages.), #4 (This screen shot shows adding the token text to the page we assigned.), #5 (Shows the actual copyright token being rendered in a view.), #6 (Example helloworld, showing how to use the HTML tab.), #7 (Example helloworld, showing how to use the PHP tab.), #8 (Example helloworld, showing how to use the CSS tab.), #9 (Example helloworld, showing how to use the JS tab.), #10 (Shows the actual helloworld token being rendered in a view.), #11 (Shows the actual helloworld token running the javascript onclick.), #12 (The error handler showing a PHP error on the page.), #13 (Show all key value pairs for the page with settings turned on.), #14 (Shows the token ordering for processing tokens in a specific custom order.), #15 (Shows the code editor for the tokens.)
- Tags: There are too many tags (12 tag instead of maximum 10)
token-manager/token-manager.php Passed 13 tests
"Token Manager" version 1.0.4's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
131 characters long description:
The Token Manager allows web developers to program PHP, HTML, CSS and JavaScript into tokens that can be used throughout Wordpress.
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
There were no executable files found in this plugin8,575 lines of code in 41 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
JavaScript | 24 | 405 | 371 | 5,719 |
PHP | 13 | 380 | 193 | 2,487 |
CSS | 4 | 46 | 14 | 369 |
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 code | 0.34 |
Average class complexity | 32.50 |
▷ Minimum class complexity | 12.00 |
▷ Maximum class complexity | 69.00 |
Average method complexity | 5.26 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 32.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 10 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 10 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 74 | |
▷ Static methods | 17 | 22.97% |
▷ Public methods | 64 | 86.49% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 10 | 13.51% |
Functions | 0 | |
▷ Named functions | 0 | 0.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
It is recommended to compress PNG files in your plugin to minimize bandwidth usage
37 PNG files occupy 0.43MB with 0.16MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
icons/up.png | 0.54KB | 0.45KB | ▼ 17.77% |
icons/icon1_32.png | 2.14KB | 1.63KB | ▼ 23.84% |
icons/history.png | 0.84KB | 0.73KB | ▼ 13.30% |
screenshot-1.png | 35.31KB | 12.66KB | ▼ 64.13% |
screenshot-14.png | 23.33KB | 8.00KB | ▼ 65.70% |