Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed gracefully, with no errors
Server metrics [RAM: ▼0.10MB] [CPU: ▼15.51ms] Passed 4 tests
An overview of server-side resources used by HTML代码优化工具
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.47 ▲0.00 | 33.95 ▼10.87 |
Dashboard /wp-admin | 3.32 ▼0.03 | 44.73 ▼17.58 |
Posts /wp-admin/edit.php | 3.37 ▲0.01 | 45.87 ▼1.33 |
Add New Post /wp-admin/post-new.php | 5.50 ▼0.38 | 68.42 ▼32.25 |
Media Library /wp-admin/upload.php | 3.24 ▲0.01 | 34.12 ▲3.68 |
HTML代码优化工具 /wp-admin/options-general.php?page=cht_pack | 3.27 | 33.40 |
Server storage [IO: ▲0.18MB] [DB: ▲0.00MB] Passed 3 tests
How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 11 new files
Database: no new tables, 6 new options
New WordPress options |
---|
db_upgraded |
can_compress_scripts |
widget_recent-posts |
widget_theysaidso_widget |
theysaidso_admin_options |
widget_recent-comments |
Browser metrics Passed 4 tests
HTML代码优化工具: an overview of browser usage
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,793 ▲32 | 14.36 ▲0.00 | 1.63 ▲0.17 | 42.85 ▲1.44 |
Dashboard /wp-admin | 2,199 ▲19 | 5.50 ▼0.15 | 79.35 ▼5.65 | 41.57 ▲1.97 |
Posts /wp-admin/edit.php | 2,104 ▲4 | 2.01 ▲0.02 | 34.29 ▼4.28 | 38.40 ▲0.30 |
Add New Post /wp-admin/post-new.php | 1,538 ▲10 | 23.16 ▲0.11 | 674.23 ▲13.83 | 54.79 ▲7.95 |
Media Library /wp-admin/upload.php | 1,404 ▲7 | 4.18 ▼0.03 | 92.03 ▼9.78 | 45.86 ▲1.22 |
HTML代码优化工具 /wp-admin/options-general.php?page=cht_pack | 3,007 | 3.37 | 77.96 | 218.38 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% 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
- This plugin did not uninstall successfully, leaving 6 options in the database
- db_upgraded
- widget_theysaidso_widget
- theysaidso_admin_options
- can_compress_scripts
- widget_recent-posts
- widget_recent-comments
Smoke tests 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though no errors were found, this is by no means an exhaustive test
SRP 0% 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
Please take a closer look at the following
- 2× PHP files output text when accessed directly:
- > /wp-content/plugins/clear-html-tags/tpl/action_dialog.php
- > /wp-content/plugins/clear-html-tags/settings.php
- 15× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
- > PHP Notice
Undefined variable: cht_opt in wp-content/plugins/clear-html-tags/tpl/action_dialog.php on line 87
- > PHP Notice
Trying to access array offset on value of type null in wp-content/plugins/clear-html-tags/tpl/action_dialog.php on line 54
- > PHP Warning
Use of undefined constant CLEAR_HTML_TAGS_VERSION - assumed 'CLEAR_HTML_TAGS_VERSION' (this will throw an Error in a future version of PHP) in wp-content/plugins/clear-html-tags/settings.php on line 14
- > PHP Warning
Invalid argument supplied for foreach() in wp-content/plugins/clear-html-tags/tpl/action_dialog.php on line 76
- > PHP Notice
Trying to access array offset on value of type null in wp-content/plugins/clear-html-tags/tpl/action_dialog.php on line 26
- > PHP Notice
Undefined variable: cht_cnf in wp-content/plugins/clear-html-tags/tpl/action_dialog.php on line 76
- > PHP Notice
Undefined variable: setting_url in wp-content/plugins/clear-html-tags/tpl/action_dialog.php on line 94
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/clear-html-tags/index.php:14
- > PHP Warning
Invalid argument supplied for foreach() in wp-content/plugins/clear-html-tags/tpl/action_dialog.php on line 54
- > PHP Notice
Trying to access array offset on value of type null in wp-content/plugins/clear-html-tags/tpl/action_dialog.php on line 76
- > PHP Notice
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 on the user side
Optimizations
Plugin configuration 93% from 29 tests
readme.txt Passed 16 tests
You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
1 plugin tags: html
clear-html-tags/index.php 85% from 13 tests
"HTML代码优化工具" version 1.1.2's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
The following require your attention:
- Description: The description should be shorter than 140 characters (currently 225 characters long)
- Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("clear-html-tags.php" instead of "index.php")
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 plugin483 lines of code in 10 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 4 | 93 | 50 | 477 |
JavaScript | 4 | 0 | 0 | 4 |
CSS | 2 | 0 | 12 | 2 |
PHP code Passed 2 tests
Analyzing logical lines of code, cyclomatic complexity, and other code metrics
No complexity issues detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.32 |
Average class complexity | 25.00 |
▷ Minimum class complexity | 25.00 |
▷ Maximum class complexity | 25.00 |
Average method complexity | 2.85 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 8.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 1 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 1 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 13 | |
▷ Static methods | 11 | 84.62% |
▷ Public methods | 13 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 0 | |
▷ Named functions | 0 | 0.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 4 | |
▷ Global constants | 4 | 100.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
No PNG files were detected