Benchmarks
Plugin footprint 40% from 16 tests
Installer 0% from 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Please fix the following installer errors
- Install procedure had errors
- > Deprecated in wp-content/plugins/my-shortcodes/libs/widget.php+4
Methods with the same name as their class will not be constructors in a future version of PHP; msc_widget has a deprecated constructor
Server metrics [RAM: ▼1.08MB] [CPU: ▼44.86ms] Passed 4 tests
Analyzing server-side resources used by My Shortcodes
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.91 ▼0.55 | 8.66 ▼27.90 |
Dashboard /wp-admin | 2.93 ▼0.37 | 9.44 ▼37.13 |
Posts /wp-admin/edit.php | 2.93 ▼0.42 | 12.79 ▼32.92 |
Add New Post /wp-admin/post-new.php | 2.93 ▼2.96 | 10.16 ▼81.50 |
Media Library /wp-admin/upload.php | 2.93 ▼0.30 | 10.57 ▼22.26 |
Server storage [IO: ▲1.89MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 105 new files
Database: no new tables, 7 new options
New WordPress options |
---|
widget_theysaidso_widget |
widget_recent-posts |
widget_recent-comments |
db_upgraded |
theysaidso_admin_options |
widget_ceelements |
can_compress_scripts |
Browser metrics Passed 4 tests
This is an overview of browser requirements for My Shortcodes
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,810 ▲49 | 14.33 ▼0.40 | 1.57 ▼0.10 | 41.31 ▼3.31 |
Dashboard /wp-admin | 2,219 ▲44 | 5.57 ▼0.08 | 90.61 ▼17.58 | 36.31 ▼1.52 |
Posts /wp-admin/edit.php | 2,121 ▲24 | 2.03 ▲0.03 | 37.44 ▼2.88 | 39.10 ▼0.97 |
Add New Post /wp-admin/post-new.php | 1,553 ▲25 | 18.20 ▼4.75 | 613.76 ▼27.04 | 75.58 ▲6.74 |
Media Library /wp-admin/upload.php | 1,424 ▲30 | 4.09 ▼0.04 | 102.36 ▼0.19 | 41.62 ▼3.88 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
- Uninstall procedure validation failed for this plugin
- > Deprecated in wp-content/plugins/my-shortcodes/libs/widget.php+4
Methods with the same name as their class will not be constructors in a future version of PHP; msc_widget has a deprecated constructor
- Zombie WordPress options were found after uninstall: 7 options
- widget_theysaidso_widget
- widget_recent-comments
- theysaidso_admin_options
- widget_ceelements
- widget_recent-posts
- db_upgraded
- can_compress_scripts
Smoke tests 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though no errors were found, this is by no means an exhaustive test
SRP 0% 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
- 8× PHP files perform the action of outputting non-empty strings when accessed directly:
- > /wp-content/plugins/my-shortcodes/libs/libraries.php
- > /wp-content/plugins/my-shortcodes/libs/preview.php
- > /wp-content/plugins/my-shortcodes/libs/php.php
- > /wp-content/plugins/my-shortcodes/libs/template.php
- > /wp-content/plugins/my-shortcodes/libs/variables.php
- > /wp-content/plugins/my-shortcodes/libs/assets.php
- > /wp-content/plugins/my-shortcodes/libs/css.php
- > /wp-content/plugins/my-shortcodes/libs/javascript.php
- 17× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/my-shortcodes/libs/alwaysload.php:3
- > PHP Fatal error
Uncaught Error: Call to undefined function get_option() in wp-content/plugins/my-shortcodes/libs/settings.php:3
- > PHP Fatal error
Uncaught Error: Call to undefined function msc_detectRogues() in wp-content/plugins/my-shortcodes/admin.php:26
- > PHP Fatal error
Uncaught Error: Call to undefined function stripslashes_deep() in wp-content/plugins/my-shortcodes/libs/editorpreview.php:18
- > PHP Notice
Trying to access array offset on value of type null in wp-content/plugins/my-shortcodes/admin.php on line 19
- > PHP Warning
Use of undefined constant MYSHORTCODES_VER - assumed 'MYSHORTCODES_VER' (this will throw an Error in a future version of PHP) in wp-content/plugins/my-shortcodes/admin.php on line 8
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/my-shortcodes/libs/actions.php:8
- > PHP Fatal error
Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/my-shortcodes/libs/widget.php:4
- > PHP Notice
Undefined variable: settings in wp-content/plugins/my-shortcodes/admin.php on line 19
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/my-shortcodes/plugincore.php:12
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration 87% from 29 tests
readme.txt 88% from 16 tests
The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
These attributes need to be fixed:
- Tags: Please delete some tags, you are using 11 tag instead of maximum 10
- Screenshots: These screenshots require images: #1 (You admin panel. Manage, edit, activate & export elements and shortcodes.), #2 (View a summary of your element for easy reference.), #3 (Element settings - with live preview.), #4 (Add external and WordPress provided librries for CSS and Javascript.), #5 (Clean editor with custom syntax hightlighting on built in tags like [loop] and [if] and your attriburtes in {{att}} tags.), #6 (Create dedicated widgets, with custom config panels for your attributes.)
my-shortcodes/plugincore.php 85% from 13 tests
The primary PHP file in "My Shortcodes" version 2.3 is used by WordPress to initiate all plugin functionality
Please make the necessary changes and fix the following:
- Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("my-shortcodes.php" instead of "plugincore.php")
- Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 164 characters long)
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
No dangerous file extensions were detected17,716 lines of code in 70 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
JavaScript | 23 | 905 | 740 | 8,059 |
PHP | 23 | 822 | 212 | 5,038 |
CSS | 14 | 215 | 131 | 3,397 |
HTML | 9 | 112 | 1 | 1,142 |
Markdown | 1 | 32 | 0 | 80 |
PHP code Passed 2 tests
A short review of cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.47 |
Average class complexity | 32.67 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 74.00 |
Average method complexity | 9.64 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 51.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 3 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 3 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 11 | |
▷ Static methods | 1 | 9.09% |
▷ Public methods | 11 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 55 | |
▷ Named functions | 55 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 3 | |
▷ Global constants | 3 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size 50% from 2 tests
Image compression 50% from 2 tests
It is recommended to compress PNG files in your plugin to minimize bandwidth usage
33 PNG files occupy 1.12MB with 0.73MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
screenshot-3.png | 219.20KB | 76.00KB | ▼ 65.33% |
editorcss/img/caldera-icon-assets.png | 1.43KB | 0.67KB | ▼ 52.93% |
screenshot-6.png | 131.71KB | 32.97KB | ▼ 74.97% |
editorcss/img/old-caldera-icon-edit.png | 4.84KB | 2.78KB | ▼ 42.48% |
editorcss/img/caldera-icon-edit.png | 1.30KB | 0.12KB | ▼ 91.05% |