Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully
Server metrics [RAM: ▲0.01MB] [CPU: ▼2.66ms] Passed 4 tests
Analyzing server-side resources used by Printer-Friendly WP
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.47 ▲0.01 | 34.12 ▼5.36 |
Dashboard /wp-admin | 3.32 ▲0.02 | 43.02 ▲0.23 |
Posts /wp-admin/edit.php | 3.37 ▲0.01 | 44.55 ▼1.88 |
Add New Post /wp-admin/post-new.php | 5.90 ▲0.01 | 89.00 ▼3.24 |
Media Library /wp-admin/upload.php | 3.24 ▲0.01 | 32.61 ▼0.17 |
Printer-Friendly WP /wp-admin/options-general.php?page=print_postpage_comments | 3.21 | 28.61 |
Server storage [IO: ▲0.09MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 7 new files
Database: no new tables, 8 new options
New WordPress options |
---|
print_button_pages |
widget_recent-posts |
theysaidso_admin_options |
print_button_posts |
widget_theysaidso_widget |
widget_recent-comments |
can_compress_scripts |
db_upgraded |
Browser metrics Passed 4 tests
This is an overview of browser requirements for Printer-Friendly WP
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,831 ▲85 | 13.17 ▼1.41 | 1.76 ▲0.02 | 37.14 ▼5.57 |
Dashboard /wp-admin | 2,213 ▲25 | 4.87 ▼0.02 | 95.64 ▼8.46 | 38.11 ▼6.45 |
Posts /wp-admin/edit.php | 2,093 ▲1 | 2.05 ▼0.13 | 39.29 ▲4.37 | 36.02 ▼2.88 |
Add New Post /wp-admin/post-new.php | 1,539 ▲25 | 23.23 ▲5.76 | 604.74 ▼72.60 | 51.42 ▲0.49 |
Media Library /wp-admin/upload.php | 1,386 ▼2 | 4.22 ▲0.04 | 98.14 ▼4.30 | 41.22 ▼5.43 |
Printer-Friendly WP /wp-admin/options-general.php?page=print_postpage_comments | 813 | 2.03 | 23.23 | 23.86 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
- This plugin does not fully uninstall, leaving 6 options in the database
- widget_recent-comments
- widget_theysaidso_widget
- db_upgraded
- widget_recent-posts
- theysaidso_admin_options
- can_compress_scripts
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though everything seems fine, this is not an exhaustive test
SRP 50% 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
- 5× GET requests to PHP files trigger server-side errors or Error 500 responses:
- > PHP Fatal error
Uncaught Error: Call to undefined function is_admin() in wp-content/plugins/printer-friendly-wp/printpostpage.php:17
- > PHP Notice
Undefined index: arl in wp-content/plugins/printer-friendly-wp/print.php on line 10
- > PHP Fatal error
require_once(): Failed opening required 'wp-load.php' (include_path='.:/usr/share/php') in wp-content/plugins/printer-friendly-wp/print.php on line 12
- > PHP Warning
require_once(wp-load.php): failed to open stream: No such file or directory in wp-content/plugins/printer-friendly-wp/print.php on line 12
- > PHP Notice
Undefined index: id in wp-content/plugins/printer-friendly-wp/print.php on line 9
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration 90% 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
Please fix the following attributes:
- Screenshots: Add an image for screenshot #1 (print1.png)
printer-friendly-wp/printpostpage.php 85% from 13 tests
The main file in "Printer-Friendly WP" v. 0.0.4 serves as a complement to information provided in readme.txt and as the entry point to the plugin
The following require your attention:
- Description: Please don't use more than 140 characters for the plugin description (currently 251 characters long)
- Main file name: Name the main plugin file the same as the plugin slug ("printer-friendly-wp.php" instead of "printpostpage.php")
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
There were no executable files found in this plugin126 lines of code in 4 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 3 | 45 | 26 | 112 |
CSS | 1 | 3 | 0 | 14 |
PHP code Passed 2 tests
A brief analysis of cyclomatic complexity and code structure for this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.30 |
Average class complexity | 0.00 |
▷ Minimum class complexity | 0.00 |
▷ Maximum class complexity | 0.00 |
Average method complexity | 0.00 |
▷ Minimum method complexity | 0.00 |
▷ Maximum method complexity | 0.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 0 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 0 | 0.00% |
▷ Final classes | 0 | 0.00% |
Methods | 0 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 0 | 0.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 4 | |
▷ Named functions | 4 | 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
Often times overlooked, PNG files can occupy unnecessary space in your plugin
2 PNG files occupy 0.09MB with 0.04MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
print1.png | 85.54KB | 35.35KB | ▼ 58.67% |
img/print.png | 2.05KB | 1.50KB | ▼ 26.68% |