Benchmarks
Plugin footprint Passed 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully
Server metrics [RAM: ▲0.36MB] [CPU: ▼136.78ms] Passed 4 tests
A check of server-side resources used by AddFunc Backgrounds
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.98 ▲0.14 | 37.06 ▲2.04 |
Dashboard /wp-admin | 3.55 ▲0.50 | 49.60 ▲3.18 |
Posts /wp-admin/edit.php | 3.56 ▲0.45 | 49.96 ▲5.98 |
Add New Post /wp-admin/post-new.php | 5.80 ▲0.37 | 91.97 ▼557.73 |
Media Library /wp-admin/upload.php | 3.56 ▲0.55 | 35.16 ▲5.40 |
Backgrounds /wp-admin/edit.php?post_type=background | 3.56 | 41.06 |
Add New /wp-admin/post-new.php?post_type=background | 3.56 | 47.37 |
Server storage [IO: ▲0.24MB] [DB: ▲0.00MB] Passed 3 tests
Filesystem and database footprint
This plugin installed successfully
Filesystem: 10 new files
Database: no new tables, no new options
Browser metrics Passed 4 tests
This is an overview of browser requirements for AddFunc Backgrounds
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,718 ▲122 | 15.96 ▲0.38 | 9.68 ▼0.27 | 42.70 ▼2.09 |
Dashboard /wp-admin | 3,002 ▲68 | 5.91 ▼0.09 | 143.03 ▼9.47 | 104.82 ▼3.81 |
Posts /wp-admin/edit.php | 2,774 ▲38 | 2.73 ▲0.02 | 68.75 ▲2.49 | 85.75 ▼1.21 |
Add New Post /wp-admin/post-new.php | 1,697 ▲199 | 20.91 ▲2.12 | 281.84 ▼124.75 | 118.49 ▲10.68 |
Media Library /wp-admin/upload.php | 1,842 ▲35 | 5.02 ▼0.01 | 152.11 ▼8.77 | 117.23 ▲12.75 |
Backgrounds /wp-admin/edit.php?post_type=background | 1,683 | 4.49 | 103.19 | 67.18 |
Add New /wp-admin/post-new.php?post_type=background | 6,658 | 4.84 | 124.96 | 132.44 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests
🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Uninstall script ran successfully
Smoke tests 25% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Almost there, just fix the following server-side errors
- 8 occurences, only the last one shown
- > GET request to /wp-admin/post-new.php?post_type=background
- > Notice in wp-content/plugins/addfunc-backgrounds/metaboxes.php+1165
Undefined variable: fieldcss
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
Almost there! Just fix the following items
- 2× PHP files trigger server errors when accessed directly:
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/addfunc-backgrounds/metaboxes.php:10
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/addfunc-backgrounds/addfunc-backgrounds.php:24
- > PHP Fatal error
User-side errors 0% from 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Please fix the following browser errors
- > GET request to /wp-admin/edit.php?post_type=background
- > Javascript (severe) in unknown
/wp-admin/edit.php?post_type=background 968:4 Uncaught TypeError: $ is not a function
- > GET request to /wp-admin/edit.php?post_type=background
- > Console-api (warning) in unknown
/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,moxiejs,plupload&ver=5.8.1 1:31592 "jQuery.Deferred exception: $(...).live is not a function" "TypeError: $(...).live is not a function\n at HTMLDocument.\u003Canonymous> (/wp-content/plugins/addfunc-backgrounds/js/addfunc-backgrounds-admin.js?ver=1637344151:4:22)\n at e (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,moxiejs,plupload&ver=5.8.1:2:30038)\n at t (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,moxiejs,plupload&ver=5.8.1:2:30340)" undefined
- 2 occurences, only the last one shown
- > GET request to /wp-admin/post-new.php?post_type=background
- > Javascript (severe) in unknown
/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,moxiejs,plupload&ver=5.8.1 1:31702 Uncaught TypeError: $(...).live is not a function
- > GET request to /wp-admin/post-new.php?post_type=background
- > Javascript (severe) in unknown
/wp-admin/post-new.php?post_type=background 2221:4 Uncaught TypeError: $ is not a function
- > GET request to /wp-admin/post-new.php?post_type=background
- > Console-api (warning) in unknown
/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,moxiejs,plupload&ver=5.8.1 1:31592 "jQuery.Deferred exception: $(...).live is not a function" "TypeError: $(...).live is not a function\n at HTMLDocument.\u003Canonymous> (/wp-content/plugins/addfunc-backgrounds/js/addfunc-backgrounds-admin.js?ver=1637344153:4:22)\n at e (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,moxiejs,plupload&ver=5.8.1:2:30038)\n at t (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,moxiejs,plupload&ver=5.8.1:2:30340)" undefined
Optimizations
Plugin configuration Passed 29 tests
readme.txt Passed 16 tests
The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
6 plugin tags: backgrounds, fixed background, parallax background, multi-layer background, video background...
addfunc-backgrounds/addfunc-backgrounds.php Passed 13 tests
The principal PHP file in "AddFunc Backgrounds" v. 0.10 is loaded by WordPress automatically on each request
89 characters long description:
Create Backgrounds and choose them from a dropdown on any Post, Page or custom post type.
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Everything looks great! No dangerous files found in this plugin3,193 lines of code in 8 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 3 | 42 | 62 | 1,930 |
CSS | 2 | 79 | 69 | 986 |
JavaScript | 3 | 22 | 8 | 277 |
PHP code Passed 2 tests
An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.75 |
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 | 22 | |
▷ Named functions | 22 | 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
PNG files should be compressed to save space and minimize bandwidth usage
1 PNG file occupies 0.07MB with 0.03MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
css/jquery.minicolors.png | 67.02KB | 34.31KB | ▼ 48.80% |