Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Install script ran successfully
Server metrics [RAM: ▲0.09MB] [CPU: ▼3.02ms] Passed 4 tests
An overview of server-side resources used by Header and Footer Snippets
This plugin does not affect your website's performance
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.56 ▲0.10 | 38.02 ▼0.55 |
Dashboard /wp-admin | 3.38 ▲0.07 | 46.22 ▼4.59 |
Posts /wp-admin/edit.php | 3.49 ▲0.14 | 51.48 ▲6.34 |
Add New Post /wp-admin/post-new.php | 5.98 ▲0.10 | 86.59 ▼8.72 |
Media Library /wp-admin/upload.php | 3.30 ▲0.07 | 34.79 ▲1.79 |
Server storage [IO: ▲0.02MB] [DB: ▲0.00MB] Passed 3 tests
Filesystem and database footprint
No storage issues were detected
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options |
---|
widget_theysaidso_widget |
can_compress_scripts |
widget_recent-comments |
widget_recent-posts |
theysaidso_admin_options |
db_upgraded |
Browser metrics Passed 4 tests
An overview of browser requirements for Header and Footer Snippets
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,821 ▲86 | 13.29 ▼1.08 | 4.56 ▲2.91 | 39.51 ▲0.19 |
Dashboard /wp-admin | 2,227 ▲39 | 4.87 ▼0.03 | 109.51 ▼9.36 | 39.68 ▼1.04 |
Posts /wp-admin/edit.php | 2,108 ▲19 | 2.05 ▲0.04 | 36.76 ▲1.68 | 31.72 ▼4.29 |
Add New Post /wp-admin/post-new.php | 6,521 ▲4,987 | 20.15 ▼3.07 | 901.31 ▲266.68 | 63.92 ▼6.50 |
Media Library /wp-admin/upload.php | 1,413 ▲25 | 4.24 ▲0.07 | 98.06 ▼6.22 | 44.18 ▲0.64 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
- This plugin does not fully uninstall, leaving 6 options in the database
- can_compress_scripts
- widget_theysaidso_widget
- db_upgraded
- theysaidso_admin_options
- widget_recent-posts
- widget_recent-comments
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not an exhaustive test
SRP 50% from 2 tests
🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following
- 1× GET requests to PHP files have triggered server-side errors or warnings:
- > PHP Fatal error
Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/header-and-footer-snippets/headandfoot.php:506
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser issues were found
Optimizations
Plugin configuration 96% from 29 tests
readme.txt Passed 16 tests
The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
5 plugin tags: javascript, header, footer, css, snippets
header-and-footer-snippets/headandfoot.php 92% from 13 tests
The main PHP script in "Header and Footer Snippets" version 0.9 is automatically included on every request by WordPress
It is important to fix the following:
- Main file name: Name the main plugin file the same as the plugin slug ("header-and-footer-snippets.php" instead of "headandfoot.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
There were no executable files found in this plugin300 lines of code in 1 file:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 1 | 134 | 85 | 300 |
PHP code Passed 2 tests
This is a short overview of cyclomatic complexity and code structure for this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.19 |
Average class complexity | 27.00 |
▷ Minimum class complexity | 27.00 |
▷ Maximum class complexity | 27.00 |
Average method complexity | 1.75 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 10.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 | 13 | |
▷ Static methods | 3 | 23.08% |
▷ Public methods | 13 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 6 | |
▷ Named functions | 2 | 33.33% |
▷ Anonymous functions | 4 | 66.67% |
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
There are no PNG files in this plugin