Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
This plugin's installer ran successfully
Server metrics [RAM: ▲0.01MB] [CPU: ▼1.51ms] Passed 4 tests
This is a short check of server-side resources used by Content Protection and Disable Right Click
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.47 ▲0.01 | 34.69 ▼2.71 |
Dashboard /wp-admin | 3.32 ▲0.01 | 43.66 ▼2.33 |
Posts /wp-admin/edit.php | 3.37 ▲0.01 | 48.86 ▲3.05 |
Add New Post /wp-admin/post-new.php | 5.90 ▲0.01 | 92.34 ▼1.85 |
Media Library /wp-admin/upload.php | 3.24 ▲0.01 | 34.92 ▲0.86 |
Server storage [IO: ▲0.62MB] [DB: ▲0.00MB] Passed 3 tests
Filesystem and database footprint
No storage issues were detected
Filesystem: 9 new files
Database: no new tables, 9 new options
New WordPress options |
---|
Content_ProtectInputField4 |
widget_recent-posts |
theysaidso_admin_options |
Content_ProtectInputField3 |
widget_recent-comments |
Content_ProtectInputField2 |
can_compress_scripts |
db_upgraded |
widget_theysaidso_widget |
Browser metrics Passed 4 tests
An overview of browser requirements for Content Protection and Disable Right Click
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,815 ▲26 | 13.19 ▲0.00 | 1.69 ▲0.11 | 41.35 ▲3.86 |
Dashboard /wp-admin | 2,221 ▲12 | 4.92 ▼0.91 | 99.47 ▲4.18 | 65.79 ▲27.18 |
Posts /wp-admin/edit.php | 2,110 ▲21 | 1.99 ▼0.06 | 39.29 ▲2.61 | 33.83 ▼0.30 |
Add New Post /wp-admin/post-new.php | 1,537 ▼5 | 22.93 ▲4.85 | 716.43 ▲86.10 | 47.38 ▼11.10 |
Media Library /wp-admin/upload.php | 1,397 ▲6 | 4.21 ▲0.04 | 95.76 ▲0.08 | 70.92 ▲29.13 |
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
You still need to fix the following
- This plugin did not uninstall successfully, leaving 9 options in the database
- Content_ProtectInputField4
- can_compress_scripts
- Content_ProtectInputField3
- widget_recent-posts
- widget_theysaidso_widget
- Content_ProtectInputField2
- widget_recent-comments
- db_upgraded
- theysaidso_admin_options
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Everything seems fine, however this is by no means 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
- 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
- > PHP Fatal error
Uncaught Error: Call to undefined function get_site_url() in wp-content/plugins/content-protection-and-disable-right-click/Settings.php:2
- > 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 96% from 29 tests
readme.txt Passed 16 tests
The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
5 plugin tags: text selection, view source, copy paste, disable right click, content protection
content-protection-and-disable-right-click/ContentProtection-GSF.php 92% from 13 tests
Analyzing the main PHP file in "Content Protection and Disable Right Click" version 1.0
It is important to fix the following:
- Main file name: It is recommended to name the main PHP file as the plugin slug ("content-protection-and-disable-right-click.php" instead of "ContentProtection-GSF.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
No dangerous file extensions were detected186 lines of code in 2 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 2 | 73 | 25 | 186 |
PHP code Passed 2 tests
Analyzing 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.41 |
Average class complexity | 5.00 |
▷ Minimum class complexity | 5.00 |
▷ Maximum class complexity | 5.00 |
Average method complexity | 1.57 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 3.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 1 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 1 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 7 | |
▷ Static methods | 2 | 28.57% |
▷ Public methods | 7 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 1 | |
▷ Named functions | 1 | 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 50% from 2 tests
Image compression 50% from 2 tests
All PNG images should be compressed to minimize bandwidth usage for end users
6 PNG files occupy 0.61MB with 0.44MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
logo.png | 14.34KB | 2.65KB | ▼ 81.55% |
screenicon.png | 5.21KB | 2.55KB | ▼ 50.97% |
thumb.png | 9.53KB | 0.48KB | ▼ 94.96% |
screenshot-2.png | 49.73KB | 16.68KB | ▼ 66.46% |
screenshot-1.png | 512.54KB | 161.27KB | ▼ 68.54% |