Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices
Server metrics [RAM: ▲0.07MB] [CPU: ▼7.72ms] Passed 4 tests
Analyzing server-side resources used by Content.ad
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.58 ▲0.12 | 43.91 ▲2.40 |
Dashboard /wp-admin | 3.38 ▲0.03 | 52.21 ▼10.57 |
Posts /wp-admin/edit.php | 3.49 ▲0.13 | 54.36 ▲1.41 |
Add New Post /wp-admin/post-new.php | 5.96 ▲0.07 | 88.28 ▼24.13 |
Media Library /wp-admin/upload.php | 3.30 ▲0.07 | 39.73 ▲4.73 |
Settings /wp-admin/admin.php?page=contentad-settings | 3.26 | 440.13 |
Widgets /wp-admin/edit.php?post_type=content_ad_widget | 3.35 | 43.24 |
Server storage [IO: ▲0.11MB] [DB: ▲0.00MB] Passed 3 tests
Analyzing filesystem and database footprints of this plugin
This plugin installed successfully
Filesystem: 24 new files
Database: no new tables, 9 new options
New WordPress options |
---|
widget_contentad__includes__widget |
theysaidso_admin_options |
can_compress_scripts |
widget_recent-comments |
widget_recent-posts |
widget_theysaidso_widget |
contentad_version |
contentad_install_key |
db_upgraded |
Browser metrics Passed 4 tests
Checking browser requirements for Content.ad
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,824 ▲63 | 14.31 ▼0.07 | 1.71 ▼0.11 | 38.45 ▼1.97 |
Dashboard /wp-admin | 2,212 ▲32 | 5.67 ▼0.03 | 91.81 ▲6.90 | 85.70 ▲39.96 |
Posts /wp-admin/edit.php | 2,129 ▲29 | 2.04 ▲0.02 | 39.50 ▲3.39 | 36.01 ▲0.19 |
Add New Post /wp-admin/post-new.php | 1,555 ▲10 | 17.69 ▼5.48 | 746.73 ▲54.13 | 51.84 ▼9.21 |
Media Library /wp-admin/upload.php | 1,429 ▲26 | 4.18 ▼0.02 | 94.82 ▼11.29 | 76.03 ▲30.68 |
Settings /wp-admin/admin.php?page=contentad-settings | 899 | 1.79 | 32.44 | 31.39 |
Widgets /wp-admin/edit.php?post_type=content_ad_widget | 1,135 | 2.11 | 45.44 | 32.21 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
- Zombie WordPress options detected upon uninstall: 8 options
- contentad_version
- widget_recent-comments
- can_compress_scripts
- theysaidso_admin_options
- db_upgraded
- widget_contentad__includes__widget
- widget_theysaidso_widget
- 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
Smoke test failed, please fix the following
- > GET request to /wp-admin/admin.php?page=contentad-settings
- > Notice in wp-content/plugins/contentad/includes/api.class.php+44
Undefined variable: contentad_log
SRP 0% 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 take a closer look at the following
- 1× GET requests to PHP files return non-empty strings:
- > /wp-content/plugins/contentad/includes/tbclose.php
- 5× GET requests to PHP files have triggered server-side errors or warnings:
- > PHP Warning
Use of undefined constant WP_PLUGIN_DIR - assumed 'WP_PLUGIN_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/contentad/contentad.php on line 37
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/contentad/includes/plugin-review.class.php:31
- > PHP Fatal error
Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/contentad/includes/widget.class.php:3
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/contentad/contentad.php:46
- > PHP Warning
Use of undefined constant WP_PLUGIN_DIR - assumed 'WP_PLUGIN_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/contentad/contentad.php on line 38
- > PHP Warning
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)
There were no browser issues found
Optimizations
Plugin configuration 93% from 29 tests
readme.txt 94% from 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
Attributes that need to be fixed:
- Tags: Please reduce the number of tags, currently 24 tag instead of maximum 10
contentad/contentad.php 92% from 13 tests
The main PHP file in "Content.ad" ver. 1.3.7 adds more information about the plugin and also serves as the entry point for this plugin
It is important to fix the following:
- Description: Please don't use more than 140 characters for the plugin description (currently 239 characters long)
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Success! There were no dangerous files found in this plugin2,181 lines of code in 17 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 13 | 227 | 185 | 1,563 |
CSS | 1 | 51 | 7 | 295 |
JavaScript | 2 | 30 | 22 | 261 |
JSON | 1 | 0 | 0 | 62 |
PHP code Passed 2 tests
This plugin's cyclomatic complexity and code structure detailed below
This plugin has no cyclomatic complexity issues
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.41 |
Average class complexity | 22.09 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 80.00 |
Average method complexity | 3.86 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 39.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 | 81 | |
▷ Static methods | 54 | 66.67% |
▷ Public methods | 77 | 95.06% |
▷ Protected methods | 1 | 1.23% |
▷ Private methods | 3 | 3.70% |
Functions | 4 | |
▷ Named functions | 4 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 10 | |
▷ Global constants | 10 | 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
6 compressed PNG files occupy 0.01MB
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
images/ca_logo.png | 2.30KB | 2.30KB | 0.08% |
images/sm_icon_active.png | 0.50KB | 0.38KB | ▼ 22.94% |
images/big_red_x.png | 1.38KB | 1.31KB | ▼ 5.04% |
images/sm_icon_inactive.png | 0.70KB | 0.55KB | ▼ 21.18% |
images/ca_icon.png | 0.31KB | 0.31KB | 0.00% |