84% popup-on-click

Code Review | Popup on Click

WordPress plugin Popup on Click scored84%from 54 tests.

About plugin

  • Plugin page: popup-on-click
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.8
  • WordPress version: 6.3.1
  • First release: Jun 15, 2017
  • Latest release: Jun 15, 2017
  • Number of updates: 2
  • Update frequency: every 0.5 days
  • Top authors: ygrebnov (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /784 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.03MB] [CPU: ▼8.17ms] Passed 4 tests

This is a short check of server-side resources used by Popup on Click
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0240.04 ▼0.64
Dashboard /wp-admin3.33 ▲0.0349.21 ▼1.32
Posts /wp-admin/edit.php3.39 ▲0.0343.81 ▼2.54
Add New Post /wp-admin/post-new.php5.91 ▲0.0381.09 ▼28.19
Media Library /wp-admin/upload.php3.26 ▲0.0333.86 ▲1.53
Popup on Click /wp-admin/options-general.php?page=popup-on-click3.2532.18

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

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 15 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_theysaidso_widget
widget_recent-comments
db_upgraded
widget_recent-posts
theysaidso_admin_options

Browser metrics Passed 4 tests

This is an overview of browser requirements for Popup on Click
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,948 ▲20213.72 ▼0.6413.77 ▲12.0353.12 ▲10.29
Dashboard /wp-admin2,213 ▲254.85 ▼0.03100.18 ▼13.2342.52 ▼2.61
Posts /wp-admin/edit.php2,096 ▲72.03 ▼0.1235.75 ▲1.1633.47 ▼2.20
Add New Post /wp-admin/post-new.php1,536 ▲323.12 ▲0.02680.72 ▲25.8651.25 ▲0.07
Media Library /wp-admin/upload.php1,386 ▼24.20 ▲0.02107.23 ▲13.2744.93 ▲5.42
Popup on Click /wp-admin/options-general.php?page=popup-on-click8502.0323.4026.88

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • db_upgraded
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
The following issues need your attention
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/popup-on-click/admin/partials/popup-on-click-admin-display.php:13

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
9 plugin tags: bootstrap modal, modal, popup on click, popup, pop-up...

popup-on-click/popup-on-click.php Passed 13 tests

The principal PHP file in "Popup on Click" v. 1.0.0 is loaded by WordPress automatically on each request
105 characters long description:
Plugin provides a possibility to display content in a popup window after user clicks on a triggering link

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 detected335 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
PHP8121359331
JavaScript1214

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.06
Average class complexity2.20
▷ Minimum class complexity1.00
▷ Maximum class complexity3.00
Average method complexity1.17
▷ Minimum method complexity1.00
▷ Maximum method complexity3.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes5
▷ Abstract classes00.00%
▷ Concrete classes5100.00%
▷ Final classes00.00%
Methods36
▷ Static methods00.00%
▷ Public methods3186.11%
▷ Protected methods00.00%
▷ Private methods513.89%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
There are no PNG files in this plugin