Benchmarks
Plugin footprint 23% from 16 tests
Installer 0% from 1 test
🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Please fix the following installer errors
- The plugin cannot be installed
- > Deprecated in wp-content/plugins/dx2-post-hit-counter/dx2posthitcounter.php+542
Function create_function() is deprecated
Server metrics [RAM: ▼1.96MB] [CPU: ▼50.40ms] Passed 4 tests
A check of server-side resources used by DX2 Post Hit Counter
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.03 ▼1.43 | 3.88 ▼40.66 |
Dashboard /wp-admin | 2.05 ▼1.25 | 5.53 ▼40.75 |
Posts /wp-admin/edit.php | 2.05 ▼1.31 | 7.67 ▼36.89 |
Add New Post /wp-admin/post-new.php | 2.05 ▼3.84 | 5.95 ▼83.29 |
Media Library /wp-admin/upload.php | 2.05 ▼1.18 | 4.86 ▼30.58 |
Todays Top Posts /wp-admin/admin.php?page=dx2-top-posts | 2.05 | 5.52 |
Server storage [IO: ▲0.21MB] [DB: ▲0.00MB] Passed 3 tests
Filesystem and database footprint
There were no storage issued detected upon installing this plugin
Filesystem: 7 new files
Database: 1 new table, 7 new options
New tables |
---|
wp_dx2hits_posthits |
New WordPress options |
---|
widget_recent-posts |
widget_recent-comments |
db_upgraded |
can_compress_scripts |
widget_theysaidso_widget |
theysaidso_admin_options |
widget_dx2hits_popular_posts_widget |
Browser metrics Passed 4 tests
An overview of browser requirements for DX2 Post Hit Counter
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,863 ▲106 | 14.69 ▲0.01 | 3.88 ▲1.76 | 41.01 ▼4.22 |
Dashboard /wp-admin | 2,258 ▲67 | 6.77 ▲1.76 | 142.04 ▲37.57 | 41.37 ▲3.93 |
Posts /wp-admin/edit.php | 2,109 ▲20 | 1.99 ▼0.04 | 36.73 ▼2.73 | 35.00 ▲1.77 |
Add New Post /wp-admin/post-new.php | 1,521 ▲1 | 23.30 ▲0.35 | 667.89 ▲52.03 | 57.86 ▼2.55 |
Media Library /wp-admin/upload.php | 1,384 ▼4 | 4.19 ▼0.05 | 96.74 ▲0.24 | 40.60 ▼1.78 |
Todays Top Posts /wp-admin/admin.php?page=dx2-top-posts | 757 | 2.05 | 24.06 | 22.91 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 25% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
- The plugin did not uninstall gracefully
- > Deprecated in wp-content/plugins/dx2-post-hit-counter/dx2posthitcounter.php+542
Function create_function() is deprecated
- Zombie tables were found after uninstall: 1 table
- wp_dx2hits_posthits
- Zombie WordPress options detected upon uninstall: 7 options
- widget_dx2hits_popular_posts_widget
- db_upgraded
- widget_recent-comments
- widget_recent-posts
- can_compress_scripts
- widget_theysaidso_widget
- theysaidso_admin_options
Smoke tests 75% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
These server-side errors were triggered
- > GET request to /wp-admin/admin.php?page=dx2-top-posts
- > Deprecated in wp-content/plugins/dx2-post-hit-counter/dx2posthitcounter.php+542
Function create_function() is deprecated
- > GET request to /wp-admin/admin.php?page=dx2-top-posts
- > Notice in wp-content/plugins/dx2-post-hit-counter/dx2posthitcounter.php+420
Undefined offset: 0
- 2 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=dx2-top-posts
- > Notice in wp-content/plugins/dx2-post-hit-counter/dx2posthitcounter.php+420
Trying to access array offset on value of type null
- > GET request to /wp-admin/admin.php?page=dx2-top-posts
- > Notice in wp-content/plugins/dx2-post-hit-counter/dx2posthitcounter.php+420
Undefined offset: 1
SRP Passed 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
Looking good! No server-side errors or output on direct access of PHP files
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 94% from 16 tests
It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
Attributes that require attention:
- Plugin Name: Please specify the plugin name on the first line (
=== dx2-post-hit-counter ===
)
dx2-post-hit-counter/dx2posthitcounter.php 92% from 13 tests
"DX2 Post Hit Counter" version 1.3's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
It is important to fix the following:
- Main file name: Name the main plugin file the same as the plugin slug ("dx2-post-hit-counter.php" instead of "dx2posthitcounter.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
Everything looks great! No dangerous files found in this plugin580 lines of code in 6 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 1 | 84 | 74 | 470 |
JavaScript | 4 | 4 | 9 | 103 |
CSS | 1 | 0 | 0 | 7 |
PHP code Passed 2 tests
Cyclomatic complexity and code structure are the fingerprint of this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.27 |
Average class complexity | 19.00 |
▷ Minimum class complexity | 19.00 |
▷ Maximum class complexity | 19.00 |
Average method complexity | 5.50 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 13.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 | 4 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 4 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 18 | |
▷ Named functions | 18 | 100.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
PNG images were not found in this plugin