Benchmarks
Plugin footprint 22% from 16 tests
Installer 0% from 1 test
🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
You still need to fix the following installer errors
- This plugin did not install gracefully
- > Warning in wp-content/plugins/commentarysandbox/commentpress-core/class_commentpress.php+4927
Use of undefined constant _FILE_ - assumed '_FILE_' (this will throw an Error in a future version of PHP)
Server metrics [RAM: ▼0.81MB] [CPU: ▼52.20ms] Passed 4 tests
An overview of server-side resources used by CommentarySandbox
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.18 ▼0.28 | 12.30 ▼28.03 |
Dashboard /wp-admin | 3.21 ▼0.13 | 13.98 ▼52.52 |
Posts /wp-admin/edit.php | 3.21 ▼0.14 | 15.44 ▼42.11 |
Add New Post /wp-admin/post-new.php | 3.21 ▼2.68 | 14.23 ▼86.13 |
Media Library /wp-admin/upload.php | 3.21 ▼0.02 | 13.62 ▼22.25 |
Customize /wp-admin/customize.php | 3.24 | 16.00 |
CommentarySandbox /wp-admin/options-general.php?page=commentpress_admin | 3.21 | 15.94 |
Header /wp-admin/themes.php?page=custom-header | 3.22 | 15.10 |
Server storage [IO: ▲4.71MB] [DB: ▲0.01MB] 67% from 3 tests
Input-output and database impact of this plugin
Just a few items left to fix
- Illegal file modification found: 1 file (4.00KB) outside of "wp-content/plugins/commentarysandbox/" and "wp-content/uploads/"
- (new file) wp-content/mgd_mirror/mgd_maximinodotpy-gitdown-test-repository
Filesystem: 342 new files
Database: 1 new table, 19 new options
New tables |
---|
wp_commentpress_new_field |
New WordPress options |
---|
template_root |
commentpress_options |
commentpress_page_for_posts |
widget_theysaidso_widget |
widget_recent-comments |
commentpress_page_comments |
current_theme |
commentpress_sidebars_widgets |
can_compress_scripts |
theme_switched |
... |
Browser metrics Passed 4 tests
This is an overview of browser requirements for CommentarySandbox
Normal browser usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,462 ▲716 | 15.03 ▲0.65 | 34.77 ▲32.95 | 48.21 ▲7.36 |
Dashboard /wp-admin | 2,245 ▲84 | 5.84 ▲0.24 | 95.26 ▼3.85 | 39.60 ▲0.57 |
Posts /wp-admin/edit.php | 2,064 ▼33 | 2.05 ▼0.07 | 40.28 ▲0.63 | 35.54 ▲1.38 |
Add New Post /wp-admin/post-new.php | 5,144 ▲3,613 | 22.86 ▼0.46 | 897.63 ▲208.26 | 123.40 ▲58.48 |
Media Library /wp-admin/upload.php | 1,423 ▲29 | 4.25 ▲0.01 | 100.14 ▼32.08 | 44.73 ▼11.12 |
Customize /wp-admin/customize.php | 7,326 | 21.70 | 632.26 | 137.23 |
CommentarySandbox /wp-admin/options-general.php?page=commentpress_admin | 1,411 | 2.07 | 24.71 | 40.44 |
Header /wp-admin/customize.php?return=%2Fwp-admin%2Fwp-api.php&autofocus%5Bcontrol%5D=header_image | 8,443 | 23.81 | 454.30 | 75.88 |
Header /wp-admin/themes.php?page=custom-header | 1,387 | 3.95 | 64.51 | 89.38 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.05MB] 25% from 4 tests
🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following items require your attention
- This plugin did not uninstall without warnings or errors
- > Warning in wp-content/plugins/commentarysandbox/commentpress-core/class_commentpress.php+4927
Use of undefined constant _FILE_ - assumed '_FILE_' (this will throw an Error in a future version of PHP)
- The uninstall procedure failed, leaving 1 table in the database
- wp_commentpress_new_field
- This plugin does not fully uninstall, leaving 13 options in the database
- template_root
- db_upgraded
- can_compress_scripts
- theme_mods_twentytwentythree
- widget_commentpress_text
- widget_theysaidso_widget
- widget_recent-comments
- theme_mods_commentpress-modern
- current_theme
- stylesheet_root
- ...
Smoke tests 0% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | This is a shallow check for server-side errors
Smoke test failed, please fix the following
- 5 occurences, only the last one shown
- > GET request to /wp-admin/themes.php?page=custom-header
- > Warning in wp-content/plugins/commentarysandbox/commentpress-core/class_commentpress.php+4927
Use of undefined constant _FILE_ - assumed '_FILE_' (this will throw an Error in a future version of PHP)
- > GET request to /wp-admin/customize.php
- > Notice in wp-content/plugins/commentarysandbox/commentpress-core/class_commentpress_display.php+625
Undefined variable: popover_textblock
- > GET request to /wp-admin/customize.php
- > Notice in wp-content/plugins/commentarysandbox/commentpress-core/class_commentpress_display.php+627
Undefined variable: popover_comment
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
Please fix the following items
- 9× PHP files output non-empty strings when accessed directly via GET requests:
- > /wp-content/plugins/commentarysandbox/themes/commentpress-flat/assets/templates/comments_by_para.php
- > /wp-content/plugins/commentarysandbox/themes/commentpress-theme/assets/templates/comments_by_para.php
- > /wp-content/plugins/commentarysandbox/themes/commentpress-theme/comments.php
- > /wp-content/plugins/commentarysandbox/themes/commentpress-modern/comments.php
- > /wp-content/plugins/commentarysandbox/themes/commentpress-flat/comments.php
- > /wp-content/plugins/commentarysandbox/themes/commentpress-theme/assets/templates/comment_form.php
- > /wp-content/plugins/commentarysandbox/themes/commentpress-modern/assets/templates/comments_by_para.php
- > /wp-content/plugins/commentarysandbox/themes/commentpress-modern/assets/templates/comment_form.php
- > /wp-content/plugins/commentarysandbox/themes/commentpress-flat/assets/templates/comment_form.php
- 138× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
- > PHP Warning
Use of undefined constant COMMENTPRESS_PLUGIN_PATH - assumed 'COMMENTPRESS_PLUGIN_PATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/commentarysandbox/themes/commentpress-modern/functions.php on line 29
- > PHP Notice
Undefined variable: wp_version in wp-content/plugins/commentarysandbox/themes/commentpress-theme/group.php on line 31
- > PHP Fatal error
Uncaught Error: Call to undefined function _e() in wp-content/plugins/commentarysandbox/themes/commentpress-flat/assets/templates/toc_dropdown.php:41
- > PHP Fatal error
Uncaught Error: Call to undefined function commentpress_get_all_comments_page_content() in wp-content/plugins/commentarysandbox/themes/commentpress-modern/comments-all.php:46
- > PHP Notice
Trying to get property 'comment_status' of non-object in wp-content/plugins/commentarysandbox/themes/commentpress-theme/assets/templates/comments_in_page.php on line 126
- > PHP Fatal error
Uncaught Error: Call to undefined function is_multisite() in wp-content/plugins/commentarysandbox/themes/commentpress-modern/assets/templates/navigation.php:551
- > PHP Fatal error
Uncaught Error: Call to undefined function get_header() in wp-content/plugins/commentarysandbox/themes/commentpress-theme/search.php:1
- > PHP Fatal error
Uncaught Error: Call to undefined function get_header() in wp-content/plugins/commentarysandbox/themes/commentpress-theme/404.php:1
- > PHP Fatal error
require_once(): Failed opening required 'COMMENTPRESS_PLUGIN_PATHcommentpress-core/assets/includes/theme/theme-functions.php' (include_path='.:/usr/share/php') in wp-content/plugins/commentarysandbox/themes/commentpress-flat/functions.php on line 29
- > PHP Fatal error
Uncaught Error: Call to undefined function get_header() in wp-content/plugins/commentarysandbox/themes/commentpress-flat/404.php:1
- > PHP Warning
User-side errors 0% from 1 test
🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Please fix the following browser errors
- > GET request to /wp-admin/customize.php
- > Security (warning) in unknown
/?customize_changeset_uuid=a8e7464e-5e78-47c8-8a50-31bf7f084e68&customize_theme=commentpress-modern&customize_messenger_channel=preview-0 - An iframe which has both allow-scripts and allow-same-origin for its sandbox attribute can escape its sandboxing.
- 2 occurences, only the last one shown
- > GET request to /wp-admin/customize.php?return=%2Fwp-admin%2Fwp-api.php&autofocus%5Bcontrol%5D=header_image
- > Network (severe)
wp-content/plugins/commentarysandbox/themes/commentpress-modern/assets/css/style.css?ver=1.1 - Failed to load resource: the server responded with a status of 404 (Not Found)
- 2 occurences, only the last one shown
- > GET request to /wp-admin/customize.php?return=%2Fwp-admin%2Fwp-api.php&autofocus%5Bcontrol%5D=header_image
- > Network (severe)
wp-content/plugins/commentarysandbox/themes/commentpress-modern/assets/css/responsive.css?ver=1.1 - Failed to load resource: the server responded with a status of 404 (Not Found)
- > GET request to /wp-admin/customize.php
- > Javascript (severe) in unknown
/?customize_changeset_uuid=a8e7464e-5e78-47c8-8a50-31bf7f084e68&customize_theme=commentpress-modern&customize_messenger_channel=preview-0 657:38 Uncaught TypeError: Cannot read properties of null (reading 'click')
- 2 occurences, only the last one shown
- > GET request to /wp-admin/customize.php?return=%2Fwp-admin%2Fwp-api.php&autofocus%5Bcontrol%5D=header_image
- > Console-api (warning) in unknown
/wp-includes/js/jquery/jquery.min.js?ver=3.7.0 1:28609 "jQuery.Deferred exception: Cannot read properties of undefined (reading 'handler')" "TypeError: Cannot read properties of undefined (reading 'handler')\n at HTMLParagraphElement.setup (/wp-content/plugins/commentarysandbox/commentpress-core/assets/js/jquery.highlighter.min.js?ver=3.9:1:288)\n at Object.add (/wp-includes/js/jquery/jquery.min.js?ver=3.7.0:2:38402)\n at Object.\u003Canonymous> (/wp-includes/js/jquery/jquery-migrate.min.js?ver=3.4.1:2:9827)\n at e.\u003Ccomputed> [as add] (/wp-includes/js/jquery/jquery-migrate.min.js?ver=3.4.1:2:1582)\n at HTMLParagraphElement.\u003Canonymous> (/wp-includes/js/jquery/jquery.min.js?ver=3.7.0:2:37080)\n at Function.each (/wp-includes/js/jquery/jquery.min.js?ver=3.7.0:2:3129)\n at e.\u003Ccomputed>.each (/wp-includes/js/jquery/jquery.min.js?ver=3.7.0:2:1594)\n at Le (/wp-includes/js/jquery/jquery.min.js?ver=3.7.0:2:37055)\n at e.\u003Ccomputed>.on (/wp-includes/js/jquery/jquery.min.js?ver=3.7.0:2:44440)\n at e.\u003Ccomputed>.\u003Canonymous> (/wp-includes/js/jquery/jquery-migrate.min.js?ver=3.4.1:2:10808)" undefined
- 2 occurences, only the last one shown
- > GET request to /wp-admin/customize.php?return=%2Fwp-admin%2Fwp-api.php&autofocus%5Bcontrol%5D=header_image
- > Javascript (severe) in unknown
/wp-includes/js/jquery/jquery.min.js?ver=3.7.0 1:28721 Uncaught TypeError: Cannot read properties of undefined (reading 'handler')
- > GET request to /wp-admin/customize.php?return=%2Fwp-admin%2Fwp-api.php&autofocus%5Bcontrol%5D=header_image
- > Security (warning) in unknown
/?customize_changeset_uuid=bbc4da20-a6d2-40e5-9c6f-befa2736e251&customize_theme=commentpress-modern&customize_messenger_channel=preview-0 - An iframe which has both allow-scripts and allow-same-origin for its sandbox attribute can escape its sandboxing.
- > GET request to /wp-admin/customize.php?return=%2Fwp-admin%2Fwp-api.php&autofocus%5Bcontrol%5D=header_image
- > Javascript (severe) in unknown
/?customize_changeset_uuid=bbc4da20-a6d2-40e5-9c6f-befa2736e251&customize_theme=commentpress-modern&customize_messenger_channel=preview-0 657:38 Uncaught TypeError: Cannot read properties of null (reading 'click')
Optimizations
Plugin configuration 90% from 29 tests
readme.txt Passed 16 tests
It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
6 plugin tags: commentpress, blogs, commentarysandbox, collaboration, dcc...
commentarysandbox/commentpress-core.php 77% from 13 tests
The main PHP script in "CommentarySandbox" version 2.2 is automatically included on every request by WordPress
The following require your attention:
- Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("commentarysandbox.php" instead of "commentpress-core.php")
- Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug
- Description: The description should be shorter than 140 characters (currently 320 characters long)
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
No dangerous file extensions were detected52,485 lines of code in 194 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
CSS | 42 | 5,229 | 2,806 | 25,148 |
PHP | 108 | 17,815 | 12,167 | 16,701 |
JavaScript | 37 | 28,488 | 5,236 | 5,894 |
PO File | 4 | 1,926 | 5,196 | 4,529 |
Markdown | 1 | 94 | 0 | 154 |
Bourne Shell | 1 | 21 | 9 | 58 |
SVG | 1 | 0 | 0 | 1 |
PHP code Passed 2 tests
Analyzing cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.40 |
Average class complexity | 72.47 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 326.00 |
Average method complexity | 3.79 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 77.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 19 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 19 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 487 | |
▷ Static methods | 9 | 1.85% |
▷ Public methods | 477 | 97.95% |
▷ Protected methods | 2 | 0.41% |
▷ Private methods | 8 | 1.64% |
Functions | 148 | |
▷ Named functions | 148 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 26 | |
▷ Global constants | 17 | 65.38% |
▷ Class constants | 9 | 34.62% |
▷ Public constants | 9 | 100.00% |
Plugin size 50% from 2 tests
Image compression 50% from 2 tests
All PNG images should be compressed to minimize bandwidth usage for end users
23 PNG files occupy 0.61MB with 0.15MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
themes/commentpress-theme/assets/images/icons/page.png | 0.62KB | 0.92KB | 0.00% |
themes/commentpress-modern/screenshot.png | 353.04KB | 120.52KB | ▼ 65.86% |
themes/commentpress-flat/assets/images/buddypress/closed.png | 0.31KB | 0.21KB | ▼ 31.11% |
themes/commentpress-theme/assets/images/icons/information.png | 0.76KB | 0.83KB | 0.00% |
themes/commentpress-flat/assets/images/icons/comment_add.png | 0.52KB | 0.38KB | ▼ 25.66% |