10% page-layered-popup

Code Review | Page Layered Popup

WordPress plugin Page Layered Popup scored 10% from 54 tests.

About plugin

  • Plugin page: page-layered-popup
  • Plugin version: 1.0.7
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-4.9
  • WordPress version: 5.9.2
  • First release: Sep 8, 2017
  • Latest release: Dec 7, 2017
  • Number of updates: 12
  • Update frequency: every 15.8 days
  • Top authors: jamesdlow (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active / 1,815 total downloads

Benchmarks

Plugin footprint 58% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
These installer errors require your attention
  • Install procedure validation failed for this plugin
    • > Warning in wp-content/plugins/page-layered-popup/page-layered-popup.php+20
    Use of undefined constant Page_Layered_Popup - assumed 'Page_Layered_Popup' (this will throw an Error in a future version of PHP)

Server metrics [RAM: ▼2.47MB] [CPU: ▼350.88ms] Passed 4 tests

This is a short check of server-side resources used by Page Layered Popup
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /1.90 ▼1.624.42 ▼52.08
Dashboard /wp-admin1.92 ▼1.494.18 ▼31.02
Posts /wp-admin/edit.php1.92 ▼1.724.16 ▼46.26
Add New Post /wp-admin/post-new.php1.92 ▼5.053.86 ▼1,274.15
Media Library /wp-admin/upload.php1.92 ▼1.388.45 ▼21.61

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 3 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

A check of browser resources used by Page Layered Popup
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,797 ▲4315.83 ▼0.196.71 ▲0.922.67 ▼0.10
Dashboard /wp-admin2,895 ▲356.11 ▼0.08115.79 ▼6.78157.56 ▼0.95
Posts /wp-admin/edit.php2,694 ▲63.24 ▼0.0092.81 ▲11.58142.52 ▼11.26
Add New Post /wp-admin/post-new.php1,685 ▲2418.21 ▲2.12405.10 ▼12.42177.09 ▲24.12
Media Library /wp-admin/upload.php1,701 ▲65.52 ▼0.01144.82 ▲4.19182.33 ▼8.26

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
  • Uninstall procedure validation failed for this plugin
    • > Warning in wp-content/plugins/page-layered-popup/page-layered-popup.php+20
    Use of undefined constant Page_Layered_Popup - assumed 'Page_Layered_Popup' (this will throw an Error in a future version of PHP)

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
The smoke test was a success, however most plugin functionality was not tested

SRP 50% 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
Please fix the following items
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/page-layered-popup/page-layered-popup.php:12

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
4 plugin tags: post, welcome, mat, popup

page-layered-popup/page-layered-popup.php Passed 13 tests

The main PHP script in "Page Layered Popup" version 1.0.7 is automatically included on every request by WordPress
107 characters long description:
Extends the layered popup plugin with the ability to show a page as popup, as well as show as a welcome mat

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
Success! There were no dangerous files found in this plugin204 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP11132160
JavaScript12344

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.39
Average class complexity28.00
▷ Minimum class complexity28.00
▷ Maximum class complexity28.00
Average method complexity3.45
▷ Minimum method complexity1.00
▷ Maximum method complexity8.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods11
▷ Static methods11100.00%
▷ Public methods11100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.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
There were not PNG files found in your plugin