Benchmarks
Plugin footprint 40% from 16 tests
Installer 0% from 1 test
🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
It is recommended to fix the following installer errors
- Install procedure validation failed for this plugin
- > Deprecated in wp-content/plugins/wp-post-to-pdf-enhanced/wp-post-to-pdf-enhanced.php+41
Methods with the same name as their class will not be constructors in a future version of PHP; wpptopdfenh has a deprecated constructor
Server metrics [RAM: ▼1.67MB] [CPU: ▼50.93ms] Passed 4 tests
This is a short check of server-side resources used by WP Post to PDF Enhanced
This plugin does not affect your website's performance
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.32 ▼1.15 | 4.46 ▼43.95 |
Dashboard /wp-admin | 2.34 ▼0.97 | 5.98 ▼41.20 |
Posts /wp-admin/edit.php | 2.34 ▼1.02 | 9.70 ▼35.86 |
Add New Post /wp-admin/post-new.php | 2.34 ▼3.55 | 6.17 ▼82.69 |
Media Library /wp-admin/upload.php | 2.34 ▼0.90 | 7.26 ▼27.52 |
WP Post to PDF Enhanced /wp-admin/options-general.php?page=wp-post-to-pdf-enhanced/wp-post-to-pdf-enhanced.php | 2.34 | 6.14 |
Server storage [IO: ▲26.78MB] [DB: ▲0.00MB] 67% from 3 tests
Input-output and database impact of this plugin
These are issues you should consider
- Total filesystem usage must be limited to 25MB (currently using 26.78MB)
Filesystem: 211 new files
Database: no new tables, 7 new options
New WordPress options |
---|
db_upgraded |
wpptopdfenh |
can_compress_scripts |
widget_theysaidso_widget |
widget_recent-comments |
theysaidso_admin_options |
widget_recent-posts |
Browser metrics Passed 4 tests
This is an overview of browser requirements for WP Post to PDF Enhanced
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,804 ▲69 | 13.39 ▼1.01 | 1.64 ▼0.30 | 38.54 ▼10.90 |
Dashboard /wp-admin | 2,210 ▲22 | 4.87 ▼1.17 | 107.27 ▼8.73 | 42.81 ▲0.59 |
Posts /wp-admin/edit.php | 2,096 ▲7 | 1.99 ▼0.03 | 43.02 ▲6.96 | 36.73 ▲2.55 |
Add New Post /wp-admin/post-new.php | 1,545 ▲31 | 18.16 ▲0.56 | 604.12 ▼36.25 | 51.49 ▼0.89 |
Media Library /wp-admin/upload.php | 1,395 ▲4 | 4.22 ▲0.03 | 104.31 ▲2.09 | 42.47 ▼0.38 |
WP Post to PDF Enhanced /wp-admin/options-general.php?page=wp-post-to-pdf-enhanced/wp-post-to-pdf-enhanced.php | 3,987 | 1.77 | 26.68 | 46.00 |
Uninstaller [IO: ▲0.01MB] [DB: ▲0.00MB] 50% from 4 tests
🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
- Uninstall procedure had uncaught errors
- > Deprecated in wp-content/plugins/wp-post-to-pdf-enhanced/wp-post-to-pdf-enhanced.php+41
Methods with the same name as their class will not be constructors in a future version of PHP; wpptopdfenh has a deprecated constructor
- The uninstall procedure has failed, leaving 7 options in the database
- wpptopdfenh
- theysaidso_admin_options
- widget_theysaidso_widget
- widget_recent-posts
- can_compress_scripts
- db_upgraded
- widget_recent-comments
Smoke tests 50% 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)
Smoke test failed, please fix the following
- > GET request to /wp-admin/options-general.php?page=wp-post-to-pdf-enhanced/wp-post-to-pdf-enhanced.php
- > Deprecated in wp-content/plugins/wp-post-to-pdf-enhanced/wp-post-to-pdf-enhanced.php+41
Methods with the same name as their class will not be constructors in a future version of PHP; wpptopdfenh has a deprecated constructor
- 29 occurences, only the last one shown
- > GET request to /wp-admin/options-general.php?page=wp-post-to-pdf-enhanced/wp-post-to-pdf-enhanced.php
- > Deprecated in wp-content/plugins/wp-post-to-pdf-enhanced/tcpdf/include/tcpdf_images.php+310
Array and string offset access syntax with curly braces is deprecated
- > GET request to /wp-admin/options-general.php?page=wp-post-to-pdf-enhanced/wp-post-to-pdf-enhanced.php
- > Warning in wp-content/plugins/wp-post-to-pdf-enhanced/tcpdf/tcpdf.php+17637
"continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"?
- > GET request to /wp-admin/options-general.php?page=wp-post-to-pdf-enhanced/wp-post-to-pdf-enhanced.php
- > Notice in wp-content/plugins/wp-post-to-pdf-enhanced/wpptopdfenh_options.php+73
Undefined index: excludeThis
- > GET request to /wp-admin/options-general.php?page=wp-post-to-pdf-enhanced/wp-post-to-pdf-enhanced.php
- > Notice in wp-content/plugins/wp-post-to-pdf-enhanced/wpptopdfenh_options.php+89
Undefined index: excludeThisCache
- 8 occurences, only the last one shown
- > GET request to /wp-admin/options-general.php?page=wp-post-to-pdf-enhanced/wp-post-to-pdf-enhanced.php
- > Notice in wp-content/plugins/wp-post-to-pdf-enhanced/wpptopdfenh_options.php+174
Undefined index: authorDetail
- > GET request to /wp-admin/options-general.php?page=wp-post-to-pdf-enhanced/wp-post-to-pdf-enhanced.php
- > Notice in wp-content/plugins/wp-post-to-pdf-enhanced/wpptopdfenh_options.php+316
Undefined index: customCss
- > GET request to /wp-admin/options-general.php?page=wp-post-to-pdf-enhanced/wp-post-to-pdf-enhanced.php
- > Notice in wp-content/plugins/wp-post-to-pdf-enhanced/wpptopdfenh_options.php+375
Undefined index: liSymbolFile
- > GET request to /wp-admin/options-general.php?page=wp-post-to-pdf-enhanced/wp-post-to-pdf-enhanced.php
- > Notice in wp-content/plugins/wp-post-to-pdf-enhanced/wpptopdfenh_options.php+421
Undefined index: customFooterText
- > GET request to /wp-admin/options-general.php?page=wp-post-to-pdf-enhanced/wp-post-to-pdf-enhanced.php
- > Notice in wp-content/plugins/wp-post-to-pdf-enhanced/wpptopdfenh_options.php+461
Undefined index: footerCellBorder
- 4 occurences, only the last one shown
- > GET request to /wp-admin/options-general.php?page=wp-post-to-pdf-enhanced/wp-post-to-pdf-enhanced.php
- > Notice in wp-content/plugins/wp-post-to-pdf-enhanced/wpptopdfenh_options.php+489
Undefined index: footerAlign
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
- 21× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
- > PHP Warning
Use of undefined constant WPPTOPDFENH_PATH - assumed 'WPPTOPDFENH_PATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/wp-post-to-pdf-enhanced/tcpdf/config/tcpdf_config.php on line 60
- > PHP Warning
Use of undefined constant WPPTOPDFENH_URL - assumed 'WPPTOPDFENH_URL' (this will throw an Error in a future version of PHP) in wp-content/plugins/wp-post-to-pdf-enhanced/tcpdf/config/tcpdf_config.php on line 79
- > PHP Warning
require_once(WPPTOPDFENH_PATH/tcpdf/tcpdf.php): failed to open stream: No such file or directory in wp-content/plugins/wp-post-to-pdf-enhanced/wpptopdfenh_shortcodes.php on line 10
- > PHP Fatal error
require_once(): Failed opening required 'WPPTOPDFENH_PATH/tcpdf/tcpdf.php' (include_path='.:/usr/share/php') in wp-content/plugins/wp-post-to-pdf-enhanced/wpptopdfenh_shortcodes.php on line 10
- > PHP Warning
Use of undefined constant WPPTOPDFENH_URL - assumed 'WPPTOPDFENH_URL' (this will throw an Error in a future version of PHP) in wp-content/plugins/wp-post-to-pdf-enhanced/tcpdf/config/tcpdf_config.php on line 79
- > PHP Warning
"continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in wp-content/plugins/wp-post-to-pdf-enhanced/tcpdf/tcpdf.php on line 17637
- > PHP Warning
Use of undefined constant WPPTOPDFENH_PATH - assumed 'WPPTOPDFENH_PATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/wp-post-to-pdf-enhanced/tcpdf/config/tcpdf_config.php on line 60
- > PHP Warning
Use of undefined constant WP_CONTENT_DIR - assumed 'WP_CONTENT_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/wp-post-to-pdf-enhanced/tcpdf/config/tcpdf_config.php on line 146
- > PHP Warning
Use of undefined constant WPPTOPDFENH_PATH - assumed 'WPPTOPDFENH_PATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/wp-post-to-pdf-enhanced/wpptopdfenh_shortcodes.php on line 10
- > PHP Warning
Use of undefined constant WPPTOPDFENH_PATH - assumed 'WPPTOPDFENH_PATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/wp-post-to-pdf-enhanced/tcpdf/config/tcpdf_config.php on line 60
- > PHP Warning
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found
Optimizations
Plugin configuration 97% from 29 tests
readme.txt 94% from 16 tests
Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
These attributes need to be fixed:
- Tags: You are using too many tags: 11 tag instead of maximum 10
wp-post-to-pdf-enhanced/wp-post-to-pdf-enhanced.php Passed 13 tests
The main PHP file in "WP Post to PDF Enhanced" ver. 1.1.1 adds more information about the plugin and also serves as the entry point for this plugin
136 characters long description:
WP Post to PDF Enhanced, based on the original WP Post to PDF, renders posts & pages as downloadable PDFs for archiving and/or printing.
Code Analysis 95% from 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Everything looks great! No dangerous files found in this plugin49,304 lines of code in 100 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 97 | 1,522 | 11,974 | 49,182 |
CSS | 1 | 6 | 0 | 78 |
JSON | 1 | 0 | 0 | 40 |
diff | 1 | 0 | 14 | 4 |
PHP code 0% from 2 tests
A brief analysis of cyclomatic complexity and code structure for this plugin
These items need your attention
- Class cyclomatic complexity should be reduced to less than 1000 (currently 4,240)
- Cyclomatic complexity of methods should be reduced to less than 100 (currently 487)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.43 |
Average class complexity | 371.94 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 4,240.00 |
Average method complexity | 9.40 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 487.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 18 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 18 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 795 | |
▷ Static methods | 106 | 13.33% |
▷ Public methods | 503 | 63.27% |
▷ Protected methods | 292 | 36.73% |
▷ Private methods | 0 | 0.00% |
Functions | 12 | |
▷ Named functions | 12 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 152 | |
▷ Global constants | 152 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
PNG files should be compressed to save space and minimize bandwidth usage
2 PNG files occupy 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
asset/images/logo.png | 11.80KB | 6.44KB | ▼ 45.40% |
asset/images/pdf.png | 1.29KB | 1.25KB | ▼ 3.63% |