Benchmarks
Plugin footprint 65% from 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.74MB] [CPU: ▼33.42ms] Passed 4 tests
Server-side resources used by Code Sample Contact Form
Server-side resource usage in normal parameters
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.63 ▲0.17 | 42.82 ▼7.16 |
Dashboard /wp-admin | 3.21 ▼0.10 | 32.76 ▼23.80 |
Posts /wp-admin/edit.php | 3.21 ▼0.15 | 28.40 ▼26.61 |
Add New Post /wp-admin/post-new.php | 3.21 ▼2.68 | 25.84 ▼71.06 |
Media Library /wp-admin/upload.php | 3.21 ▼0.02 | 27.58 ▼12.21 |
Setting /wp-admin/admin.php?page=setting_cs_contact | 3.21 | 28.92 |
Add New /wp-admin/admin.php?page=add_cs_contact | 3.21 | 28.16 |
Support /wp-admin/admin.php?page=support_cs_contact | 3.21 | 27.49 |
CS Contact /wp-admin/admin.php?page=cs_contact | 3.21 | 28.74 |
Server storage [IO: ▲0.22MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 52 new files
Database: no new tables, 6 new options
New WordPress options |
---|
db_upgraded |
widget_recent-posts |
can_compress_scripts |
widget_recent-comments |
widget_theysaidso_widget |
theysaidso_admin_options |
Browser metrics Passed 4 tests
Code Sample Contact Form: an overview of browser usage
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,918 ▲172 | 13.93 ▼0.45 | 9.08 ▲7.01 | 43.31 ▲0.25 |
Dashboard /wp-admin | 2,241 ▲53 | 4.89 ▼0.01 | 116.06 ▲11.89 | 42.41 ▲1.38 |
Posts /wp-admin/edit.php | 2,128 ▲36 | 2.23 ▲0.19 | 35.03 ▼6.70 | 32.45 ▼4.20 |
Add New Post /wp-admin/post-new.php | 1,543 ▲145 | 17.86 ▼0.01 | 688.31 ▲46.63 | 57.72 ▲12.91 |
Media Library /wp-admin/upload.php | 1,423 ▲38 | 4.24 ▲0.02 | 104.01 ▲0.05 | 41.92 ▼1.52 |
Setting /wp-admin/admin.php?page=setting_cs_contact | 1,184 | 1.95 | 27.83 | 33.72 |
Add New /wp-admin/admin.php?page=add_cs_contact | 1,529 | 2.01 | 30.90 | 41.04 |
Support /wp-admin/admin.php?page=support_cs_contact | 949 | 1.82 | 27.38 | 35.28 |
CS Contact /wp-admin/admin.php?page=cs_contact | 946 | 1.93 | 28.80 | 29.21 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
- This plugin did not uninstall without warnings or errors
- > User notice in wp-includes/functions.php+5905
Function add_submenu_page was called incorrectly. The seventh parameter passed to add_submenu_page() should be numeric representing menu position. Please see Debugging in WordPress for more information. (This message was added in version 5.3.0.)
- Zombie WordPress options were found after uninstall: 6 options
- widget_recent-comments
- theysaidso_admin_options
- widget_theysaidso_widget
- db_upgraded
- can_compress_scripts
- widget_recent-posts
Smoke tests 25% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | This is a shallow check for server-side errors
Almost there, just fix the following server-side errors
- 12 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=cs_contact
- > User notice in wp-includes/functions.php+5905
Function add_submenu_page was called incorrectly. The seventh parameter passed to add_submenu_page() should be numeric representing menu position. Please see Debugging in WordPress for more information. (This message was added in version 5.3.0.)
- > GET request to /wp-admin/admin.php?page=setting_cs_contact
- > Notice in wp-content/plugins/code-sample-contact-form/admin/controllers/wp_codesample_contact_controller.php+135
unserialize(): Error at offset 0 of 1 bytes
- 2 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=cs_contact
- > Notice in wp-content/plugins/code-sample-contact-form/admin/views/wp_codesample_contact-admin-list.php+56
Only variables should be passed by reference
- 2 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=setting_cs_contact
- > Notice in wp-content/plugins/code-sample-contact-form/admin/views/wp_codesample_contact-admin-setting.php+40
Undefined variable: capcha
- 2 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=setting_cs_contact
- > Notice in wp-content/plugins/code-sample-contact-form/admin/views/wp_codesample_contact-admin-setting.php+40
Trying to access array offset on value of type null
- 2 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=add_cs_contact
- > request to
- > Notice in wp-config.php+20
Undefined index: REQUEST_METHOD
- > GET request to /wp-admin/admin.php?page=support_cs_contact
- > Deprecated in wp-includes/class-wp-hook.php+310
Non-static method Wp_codesample_contact_controller::view_support_contact() should not be called statically
- > GET request to /wp-admin/admin.php?page=cs_contact
- > Notice in wp-content/plugins/code-sample-contact-form/admin/controllers/wp_codesample_contact_controller.php+87
Undefined index: action
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
Please fix the following
- 46× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
- > PHP Notice
Trying to access array offset on value of type null in wp-content/plugins/code-sample-contact-form/fields/email.php on line 14
- > PHP Notice
Trying to access array offset on value of type null in wp-content/plugins/code-sample-contact-form/fields/url.php on line 13
- > PHP Fatal error
Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/code-sample-contact-form/fields/number.php:21
- > PHP Fatal error
Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/code-sample-contact-form/admin/views/wp_codesample_contact-admin-setting.php:2
- > PHP Fatal error
Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/code-sample-contact-form/fields/text.php:20
- > PHP Notice
Trying to access array offset on value of type null in wp-content/plugins/code-sample-contact-form/fields/text.php on line 13
- > PHP Fatal error
Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/code-sample-contact-form/fields/url.php:20
- > PHP Notice
Trying to access array offset on value of type null in wp-content/plugins/code-sample-contact-form/fields/text.php on line 16
- > PHP Fatal error
Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/code-sample-contact-form/fields/textarea.php:18
- > PHP Notice
Undefined variable: list_attr in wp-content/plugins/code-sample-contact-form/fields/email.php on line 13
- > PHP Notice
User-side errors 0% from 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
These are user-side errors you should fix
- > GET request to /wp-admin/admin.php?page=support_cs_contact
- > Network (severe)
wp-content/plugins/wp_codesample_contact/admin/assets/images/contact.png - Failed to load resource: the server responded with a status of 404 (Not Found)
- > GET request to /wp-admin/admin.php?page=support_cs_contact
- > Network (severe)
wp-content/plugins/wp_codesample_contact/admin/assets/images/fanpage.png - Failed to load resource: the server responded with a status of 404 (Not Found)
- > GET request to /wp-admin/admin.php?page=support_cs_contact
- > Network (severe)
wp-content/plugins/wp_codesample_contact/admin/assets/images/bug.png - Failed to load resource: the server responded with a status of 404 (Not Found)
- > GET request to /wp-admin/admin.php?page=support_cs_contact
- > Network (severe)
wp-content/plugins/wp_codesample_contact/admin/assets/images/guide.png - Failed to load resource: the server responded with a status of 404 (Not Found)
- > GET request to /wp-admin/admin.php?page=support_cs_contact
- > Network (severe)
wp-content/plugins/wp_codesample_contact/admin/assets/images/pro.svg - Failed to load resource: the server responded with a status of 404 (Not Found)
Optimizations
Plugin configuration 86% from 29 tests
readme.txt 94% from 16 tests
The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Please fix the following attributes:
- Screenshots: These screenshots need descriptions #2, #3 in code-sample-contact-form/assets to your readme.txt
code-sample-contact-form/wp_codesample_contact.php 77% from 13 tests
The entry point to "Code Sample Contact Form" version 1.0.0 is a PHP file that has certain tags in its header comment area
It is important to fix the following:
- Description: Please don't use more than 140 characters for the plugin description (currently 240 characters long)
- Text Domain: The text domain follows the same naming rules as the plugin slug: lowercase characters and dashes
- Main file name: Name the main plugin file the same as the plugin slug ("code-sample-contact-form.php" instead of "wp_codesample_contact.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Good job! No executable or dangerous file extensions detected2,267 lines of code in 39 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 34 | 240 | 749 | 1,658 |
CSS | 2 | 88 | 10 | 418 |
JavaScript | 2 | 30 | 7 | 190 |
SVG | 1 | 0 | 0 | 1 |
PHP code Passed 2 tests
An short overview of logical lines of code, cyclomatic complexity, and other code metrics
All good! No complexity issues found
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.34 |
Average class complexity | 8.55 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 30.00 |
Average method complexity | 2.69 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 25.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 | 49 | |
▷ Static methods | 5 | 10.20% |
▷ Public methods | 43 | 87.76% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 6 | 12.24% |
Functions | 9 | |
▷ Named functions | 8 | 88.89% |
▷ Anonymous functions | 1 | 11.11% |
Constants | 2 | |
▷ Global constants | 2 | 100.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
7 PNG files occupy 0.07MB with 0.02MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
admin/assets/images/contact.png | 5.79KB | 5.65KB | ▼ 2.31% |
admin/assets/images/guide.png | 26.21KB | 10.24KB | ▼ 60.94% |
admin/assets/images/bug.png | 21.63KB | 8.43KB | ▼ 61.01% |
admin/assets/images/contact_support.png | 8.06KB | 8.04KB | 0.25% |
admin/assets/images/fanpage_old.png | 12.27KB | 7.19KB | ▼ 41.35% |