Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices
Server metrics [RAM: ▲0.36MB] [CPU: ▲0.86ms] Passed 4 tests
An overview of server-side resources used by Cookielay
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.83 ▲0.37 | 42.07 ▲3.59 |
Dashboard /wp-admin | 3.73 ▲0.39 | 57.26 ▼0.03 |
Posts /wp-admin/edit.php | 3.78 ▲0.42 | 52.07 ▲4.13 |
Add New Post /wp-admin/post-new.php | 6.24 ▲0.36 | 93.32 ▼1.58 |
Media Library /wp-admin/upload.php | 3.57 ▲0.34 | 35.82 ▲1.48 |
Settings /wp-admin/admin.php?page=cookielay-settings | 3.68 | 40.26 |
Shortcodes /wp-admin/admin.php?page=cookielay-shortcodes | 3.58 | 38.09 |
Dashboard /wp-admin/admin.php?page=cookielay | 3.58 | 37.71 |
Cookies /wp-admin/admin.php?page=cookielay-cookies | 3.58 | 38.09 |
Text /wp-admin/admin.php?page=cookielay-text | 3.63 | 38.48 |
Premium /wp-admin/admin.php?page=cookielay-prime | 3.58 | 35.82 |
Style /wp-admin/admin.php?page=cookielay-style | 3.66 | 36.93 |
Help & Support /wp-admin/admin.php?page=cookielay-help | 3.58 | 49.22 |
Server storage [IO: ▲12.13MB] [DB: ▲0.01MB] Passed 3 tests
Filesystem and database footprint
There were no storage issued detected upon installing this plugin
Filesystem: 618 new files
Database: 2 new tables, 12 new options
New tables |
---|
wp_cookielay_cookies |
wp_cookielay_groups |
New WordPress options |
---|
db_upgraded |
widget_theysaidso_widget |
cookielay_status |
cookielay_settings_style |
theysaidso_admin_options |
can_compress_scripts |
widget_recent-comments |
widget_recent-posts |
cookielay_settings_text |
cookielay_version |
... |
Browser metrics Passed 4 tests
This is an overview of browser requirements for Cookielay
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,065 ▲319 | 17.31 ▲2.75 | 1.70 ▼0.02 | 44.54 ▲6.51 |
Dashboard /wp-admin | 2,465 ▲277 | 8.61 ▲3.73 | 156.92 ▲51.13 | 39.88 ▼3.51 |
Posts /wp-admin/edit.php | 2,381 ▲292 | 5.81 ▲3.80 | 93.93 ▲55.98 | 32.05 ▼0.94 |
Add New Post /wp-admin/post-new.php | 1,588 ▲74 | 25.19 ▲7.67 | 657.81 ▼15.17 | 34.39 ▼34.23 |
Media Library /wp-admin/upload.php | 1,512 ▲127 | 6.05 ▲1.82 | 124.04 ▲13.13 | 44.95 ▼3.58 |
Settings /wp-admin/admin.php?page=cookielay-settings | 1,826 | 5.56 | 88.18 | 84.98 |
Shortcodes /wp-admin/admin.php?page=cookielay-shortcodes | 1,460 | 5.41 | 53.98 | 89.52 |
Dashboard /wp-admin/admin.php?page=cookielay | 1,470 | 5.44 | 53.59 | 91.07 |
Cookies /wp-admin/admin.php?page=cookielay-cookies | 1,506 | 5.44 | 54.41 | 66.26 |
Text /wp-admin/admin.php?page=cookielay-text | 1,812 | 5.44 | 54.17 | 39.04 |
Premium /wp-admin/admin.php?page=cookielay-prime | 1,339 | 5.55 | 53.78 | 74.15 |
Style /wp-admin/admin.php?page=cookielay-style | 4,309 | 6.40 | 169.56 | 49.33 |
Help & Support /wp-admin/admin.php?page=cookielay-help | 1,460 | 5.55 | 56.37 | 46.29 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
- Zombie WordPress options detected upon uninstall: 6 options
- widget_theysaidso_widget
- theysaidso_admin_options
- can_compress_scripts
- widget_recent-posts
- widget_recent-comments
- db_upgraded
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)
Everything seems fine, however this is by no means an exhaustive test
SRP 0% from 2 tests
🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Almost there! Just fix the following items
- 10× PHP files perform the action of outputting non-empty strings when accessed directly:
- > /wp-content/plugins/cookielay/includes/admin/scripts/allow/facebook_pixel.php
- > /wp-content/plugins/cookielay/includes/admin/scripts/allow/matomo.php
- > /wp-content/plugins/cookielay/includes/admin/scripts/allow/google_adsense.php
- > /wp-content/plugins/cookielay/includes/admin/scripts/allow/google_analytics.php
- > /wp-content/plugins/cookielay/includes/admin/scripts/allow/matomo_tag_manager.php
- > /wp-content/plugins/cookielay/includes/admin/scripts/allow/google_tag_manager.php
- > /wp-content/plugins/cookielay/includes/admin/scripts/allow/hubspot.php
- > /wp-content/plugins/cookielay/includes/admin/templates/partials/footer.php
- > /wp-content/plugins/cookielay/includes/public/styles/styles.php
- > /wp-content/plugins/cookielay/includes/public/templates/cookie.php
- 198× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
- > PHP Notice
Undefined variable: colors in wp-content/plugins/cookielay/includes/public/styles/styles.php on line 44
- > PHP Notice
Undefined variable: text in wp-content/plugins/cookielay/templates/cookielay-template-center.php on line 15
- > PHP Notice
Undefined variable: group in wp-content/plugins/cookielay/includes/public/templates/group.php on line 5
- > PHP Warning
Use of undefined constant COOKIELAY_ROOT_PATH - assumed 'COOKIELAY_ROOT_PATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/cookielay/includes/admin/templates/group-add.php on line 13
- > PHP Notice
Undefined variable: colors in wp-content/plugins/cookielay/includes/public/styles/styles.php on line 78
- > PHP Warning
Use of undefined constant COOKIELAY_ROOT_PATH - assumed 'COOKIELAY_ROOT_PATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/cookielay/includes/admin/templates/style.php on line 13
- > PHP Fatal error
Uncaught Error: Class 'Cookielay_Public_Frontend' not found in wp-content/plugins/cookielay/includes/public/class-cookielay-public-settings.php:11
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/cookielay/includes/public/templates/group.php:18
- > PHP Notice
Trying to access array offset on value of type null in wp-content/plugins/cookielay/includes/public/styles/styles.php on line 118
- > PHP Warning
Use of undefined constant COOKIELAY_ROOT_PATH - assumed 'COOKIELAY_ROOT_PATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/cookielay/includes/admin/templates/cookie-add.php on line 13
- > PHP Notice
User-side errors Passed 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration Passed 29 tests
readme.txt Passed 16 tests
The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
5 plugin tags: overlay, consent, borlabs, gdpr, cookie
cookielay/cookielay.php Passed 13 tests
The main file in "Cookielay" v. 1.2.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
61 characters long description:
With Cookielay you manage cookies in a privacy compliant way.
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
There were no executable files found in this plugin89,590 lines of code in 387 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
CSS | 19 | 3,125 | 195 | 44,917 |
JavaScript | 136 | 8,275 | 3,312 | 29,745 |
Sass | 104 | 1,435 | 1,289 | 9,298 |
PHP | 55 | 285 | 393 | 3,894 |
TypeScript | 62 | 0 | 4 | 487 |
Markdown | 3 | 171 | 0 | 472 |
JSON | 5 | 0 | 0 | 393 |
SVG | 3 | 0 | 2 | 384 |
PHP code Passed 2 tests
An short overview of logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity issues
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.13 |
Average class complexity | 6.56 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 75.00 |
Average method complexity | 1.91 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 47.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 25 | |
▷ Abstract classes | 2 | 8.00% |
▷ Concrete classes | 23 | 92.00% |
▷ Final classes | 0 | 0.00% |
Methods | 157 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 89 | 56.69% |
▷ Protected methods | 4 | 2.55% |
▷ Private methods | 64 | 40.76% |
Functions | 8 | |
▷ Named functions | 8 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 8 | |
▷ Global constants | 8 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
Using a strong compression for your PNG files is a great way to speed-up your plugin
No PNG images were found in this plugin