10% wpcontenteditable

Code Review | Click to Edit

WordPress plugin Click to Edit scored 10% from 54 tests.

About plugin

  • Plugin page: wpcontenteditable
  • Plugin version: 1.3
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.5
  • WordPress version: 6.3.1
  • First release: Jan 29, 2012
  • Latest release: Jan 18, 2013
  • Number of updates: 15
  • Update frequency: every 23.7 days
  • Top authors: jarednova (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 2,895 total downloads

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/wpcontenteditable/click-to-edit.php+18
    Methods with the same name as their class will not be constructors in a future version of PHP; ClickToEdit has a deprecated constructor

Server metrics [RAM: ▼1.91MB] [CPU: ▼53.62ms] Passed 4 tests

Server-side resources used by Click to Edit
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.08 ▼1.384.46 ▼36.78
Dashboard /wp-admin2.10 ▼1.216.07 ▼42.62
Posts /wp-admin/edit.php2.10 ▼1.266.29 ▼43.27
Add New Post /wp-admin/post-new.php2.10 ▼3.796.19 ▼91.79
Media Library /wp-admin/upload.php2.10 ▼1.135.15 ▼32.79
Click to Edit /wp-admin/options-general.php?page=upstatement_ce2.105.90

Server storage [IO: ▲0.02MB] [DB: ▲0.00MB] Passed 3 tests

How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 6 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-comments
widget_recent-posts
widget_theysaidso_widget
upstatement_ce_options
db_upgraded
theysaidso_admin_options
can_compress_scripts

Browser metrics Passed 4 tests

A check of browser resources used by Click to Edit
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,960 ▲22513.60 ▼0.756.62 ▲5.0041.60 ▲0.97
Dashboard /wp-admin2,210 ▲225.86 ▲0.77103.05 ▼10.9338.32 ▼6.31
Posts /wp-admin/edit.php2,093 ▲42.01 ▲0.0235.00 ▼4.9636.33 ▲0.91
Add New Post /wp-admin/post-new.php1,545 ▲218.15 ▼0.51623.72 ▲24.0550.08 ▲0.05
Media Library /wp-admin/upload.php1,395 ▲74.19 ▼0.0594.30 ▼0.7442.61 ▲0.58
Click to Edit /wp-admin/options-general.php?page=upstatement_ce7892.0425.2129.50

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% from 4 tests

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
Please fix the following items
  • This plugin cannot be uninstalled
    • > Deprecated in wp-content/plugins/wpcontenteditable/click-to-edit.php+18
    Methods with the same name as their class will not be constructors in a future version of PHP; ClickToEdit has a deprecated constructor
  • The uninstall procedure has failed, leaving 7 options in the database
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_theysaidso_widget
    • can_compress_scripts
    • upstatement_ce_options
    • widget_recent-comments

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These errors were triggered by the plugin
    • > GET request to /wp-admin/options-general.php?page=upstatement_ce
    • > Deprecated in wp-content/plugins/wpcontenteditable/click-to-edit.php+18
    Methods with the same name as their class will not be constructors in a future version of PHP; ClickToEdit has a deprecated constructor
    • > GET request to /wp-admin/options-general.php?page=upstatement_ce
    • > User deprecated in wp-includes/functions.php+5463
    Function screen_icon is deprecated since version 3.8.0 with no alternative available.
    • > GET request to /wp-admin/options-general.php?page=upstatement_ce
    • > User deprecated in wp-includes/functions.php+5463
    Function get_screen_icon is deprecated since version 3.8.0 with no alternative available.
    • > GET request to /wp-admin/options-general.php?page=upstatement_ce
    • > Notice in wp-content/plugins/wpcontenteditable/content-editable-admin.php+80
    Undefined index: upstatement_ce_options

SRP 0% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
The following issues need your attention
  • 1× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/wpcontenteditable/click-to-edit.php
  • 4× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      require_once(): Failed opening required 'ABSPATH/wp-admin/includes/plugin.php' (include_path='.:/usr/share/php') in wp-content/plugins/wpcontenteditable/content-editable-admin.php on line 3
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/wpcontenteditable/content-editable-admin.php on line 3
    • > PHP Warning
      require_once(ABSPATH/wp-admin/includes/plugin.php): failed to open stream: No such file or directory in wp-content/plugins/wpcontenteditable/content-editable-admin.php on line 3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wpcontenteditable/content-editable-ajax.php:2

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 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
8 plugin tags: editor, admin, contenteditable, content-editable, wordpress...

wpcontenteditable/click-to-edit.php 92% from 13 tests

Analyzing the main PHP file in "Click to Edit" version 1.3
The following require your attention:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("wpcontenteditable.php" instead of "click-to-edit.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
No dangerous file extensions were detected426 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP36018301
JavaScript114280
CSS111045

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.22
Average class complexity3.00
▷ Minimum class complexity3.00
▷ Maximum class complexity3.00
Average method complexity1.40
▷ Minimum method complexity1.00
▷ Maximum method complexity3.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods5
▷ Static methods00.00%
▷ Public methods5100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions24
▷ Named functions24100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
PNG images were not found in this plugin