Benchmarks
Plugin footprint 65% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Install script ran successfully
Server metrics [RAM: ▲0.47MB] [CPU: ▼5.18ms] Passed 4 tests
Analyzing server-side resources used by Online Contact Widget-多合一在线客服插件
Server-side resource usage in normal parameters
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 4.01 ▲0.55 | 42.10 ▼0.11 |
Dashboard /wp-admin | 3.80 ▲0.50 | 47.73 ▲1.83 |
Posts /wp-admin/edit.php | 3.86 ▲0.50 | 45.35 ▼1.96 |
Add New Post /wp-admin/post-new.php | 6.32 ▲0.44 | 87.75 ▼20.35 |
Media Library /wp-admin/upload.php | 3.66 ▲0.44 | 36.64 ▲1.70 |
Server storage [IO: ▲1.67MB] [DB: ▲0.00MB] Passed 3 tests
How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 54 new files
Database: 2 new tables, 6 new options
New tables |
---|
wp_ocw_contact_content |
wp_ocw_contact |
New WordPress options |
---|
widget_theysaidso_widget |
can_compress_scripts |
widget_recent-posts |
db_upgraded |
widget_recent-comments |
theysaidso_admin_options |
Browser metrics Passed 4 tests
A check of browser resources used by Online Contact Widget-多合一在线客服插件
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,057 ▲322 | 13.46 ▼1.29 | 7.62 ▲5.77 | 75.37 ▲27.84 |
Dashboard /wp-admin | 2,239 ▲48 | 4.90 ▼0.02 | 96.66 ▼7.84 | 98.95 ▲56.80 |
Posts /wp-admin/edit.php | 2,125 ▲36 | 2.02 ▲0.03 | 33.67 ▼8.79 | 43.82 ▲8.65 |
Add New Post /wp-admin/post-new.php | 1,705 ▲171 | 24.73 ▲1.60 | 637.35 ▼17.41 | 67.32 ▲17.11 |
Media Library /wp-admin/upload.php | 1,421 ▲36 | 4.23 ▲0.07 | 94.36 ▼12.78 | 82.32 ▲37.02 |
工单管理 /wp-admin/admin.php?page=wb_ocw#/wo-list | 1,450 | 7.12 | 109.15 | 146.33 |
插件设置 /wp-admin/admin.php?page=wb_ocw#/setting-base | 1,853 | 7.60 | 94.78 | 168.91 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% from 4 tests
🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
The following items require your attention
- Zombie tables were found after uninstall: 2 tables
- wp_ocw_contact
- wp_ocw_contact_content
- This plugin did not uninstall successfully, leaving 6 options in the database
- widget_recent-posts
- db_upgraded
- theysaidso_admin_options
- can_compress_scripts
- widget_theysaidso_widget
- widget_recent-comments
Smoke tests 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected
SRP 0% from 2 tests
🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
The following issues need your attention
- 2× PHP files output non-empty strings when accessed directly via GET requests:
- > /wp-content/plugins/online-contact-widget/inc/fold.tpl.php
- > /wp-content/plugins/online-contact-widget/wbm/tpl/svg.php
- 10× GET requests to PHP files have triggered server-side errors or warnings:
- > PHP Notice
Undefined variable: class_name in wp-content/plugins/online-contact-widget/inc/fold.tpl.php on line 1
- > PHP Notice
Undefined variable: position in wp-content/plugins/online-contact-widget/inc/unfold.tpl.php on line 6
- > PHP Notice
Undefined variable: position in wp-content/plugins/online-contact-widget/inc/fold.tpl.php on line 1
- > PHP Fatal error
Uncaught Error: Call to undefined function wp_is_mobile() in wp-content/plugins/online-contact-widget/inc/panel.tpl.php:6
- > PHP Notice
Undefined variable: tool_items in wp-content/plugins/online-contact-widget/inc/fold.tpl.php on line 2
- > PHP Warning
Invalid argument supplied for foreach() in wp-content/plugins/online-contact-widget/inc/fold.tpl.php on line 2
- > PHP Fatal error
Uncaught Error: Call to undefined function language_attributes() in wp-content/plugins/online-contact-widget/wbm/tpl/header.php:12
- > PHP Fatal error
Uncaught Error: Call to undefined function language_attributes() in wp-content/plugins/online-contact-widget/wbm/tpl/header.php:12
- > PHP Fatal error
Uncaught Error: Call to undefined function do_action() in wp-content/plugins/online-contact-widget/wbm/tpl/footer.php:11
- > PHP Fatal error
Uncaught Error: Call to undefined function wp_is_mobile() in wp-content/plugins/online-contact-widget/inc/unfold.tpl.php:7
- > PHP Notice
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration 93% from 29 tests
readme.txt Passed 16 tests
Often overlooked, readme.txt is one of the most important files in your plugin
5 plugin tags: email, wechat, contact, tel, qq
online-contact-widget/index.php 85% from 13 tests
"Online Contact Widget-多合一在线客服插件" version 1.0.8's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
Please take the time to fix the following:
- Main file name: Please rename the main PHP file in this plugin to the plugin slug ("online-contact-widget.php" instead of "index.php")
- Description: Keep the plugin description shorter than 140 characters (currently 221 characters long)
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
Good job! No executable or dangerous file extensions detected3,261 lines of code in 48 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 22 | 660 | 318 | 3,229 |
JavaScript | 18 | 0 | 47 | 23 |
CSS | 5 | 0 | 6 | 6 |
HTML | 2 | 0 | 0 | 2 |
SVG | 1 | 0 | 0 | 1 |
PHP code Passed 2 tests
An overview of cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.37 |
Average class complexity | 40.91 |
▷ Minimum class complexity | 2.00 |
▷ Maximum class complexity | 106.00 |
Average method complexity | 4.30 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 33.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 11 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 11 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 110 | |
▷ Static methods | 83 | 75.45% |
▷ Public methods | 105 | 95.45% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 5 | 4.55% |
Functions | 13 | |
▷ Named functions | 0 | 0.00% |
▷ Anonymous functions | 13 | 100.00% |
Constants | 5 | |
▷ Global constants | 5 | 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
2 compressed PNG files occupy 0.00MB
Potential savings
Compression of 2 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
assets/images/def_avatar.png | 1.55KB | 1.70KB | 0.00% |
assets/images/pic_head.png | 2.24KB | 2.24KB | 0.04% |