10% layered-pop

Code Review | Layered Pop

WordPress plugin Layered Pop scored10%from 54 tests.

About plugin

  • Plugin page: layered-pop
  • Plugin version: 0.11
  • PHP version: 7.4.16
  • WordPress compatibility: 3.6-4.1
  • WordPress version: 6.3.1
  • First release: Jan 28, 2014
  • Latest release: Feb 8, 2015
  • Number of updates: 3
  • Update frequency: every 125.3 days
  • Top authors: ichurakov (100%)

Code review

54 tests

User reviews

12 reviews

Install metrics

100+ active /16,381 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
You still need to fix the following installer errors
  • The plugin did not install without errors
    • > Error in wp-content/plugins/layered-pop/layered-pop.php+178
    Uncaught Error: Call to undefined function mysql_real_escape_string() in wp-content/plugins/layered-pop/layered-pop.php:178
    Stack trace:
    #0 wp-includes/class-wp-hook.php(310): lpl_class::install()
    #1 wp-includes/class-wp-hook.php(334): WP_Hook->apply_filters()
    #2 wp-includes/plugin.php(517): WP_Hook->do_action()
    #3 wp-admin/includes/plugin.php(693): do_action()

Server metrics [RAM: ▲0.00MB] [CPU: ▼0.62ms] Passed 4 tests

This is a short check of server-side resources used by Layered Pop
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0039.85 ▼2.80
Dashboard /wp-admin3.31 ▲0.0049.49 ▲2.29
Posts /wp-admin/edit.php3.36 ▲0.0049.30 ▼3.50
Add New Post /wp-admin/post-new.php5.89 ▲0.00106.46 ▲5.00
Media Library /wp-admin/upload.php3.23 ▲0.0039.01 ▲1.55

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 23 new files
Database: 1 new table, 6 new options
New tables
wp_lpl_layers
New WordPress options
widget_theysaidso_widget
theysaidso_admin_options
db_upgraded
can_compress_scripts
widget_recent-comments
widget_recent-posts

Browser metrics Passed 4 tests

A check of browser resources used by Layered Pop
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲314.20 ▼0.182.07 ▲0.4343.61 ▼0.14
Dashboard /wp-admin2,198 ▲215.65 ▼0.0191.24 ▼2.7744.63 ▲6.01
Posts /wp-admin/edit.php2,100 ▼01.99 ▼0.0341.86 ▲3.9838.63 ▲1.46
Add New Post /wp-admin/post-new.php1,526 ▼223.38 ▲0.27679.78 ▲12.8955.08 ▲3.08
Media Library /wp-admin/upload.php1,400 ▼34.15 ▼0.06104.97 ▼1.3648.17 ▲3.10

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
  • Zombie tables were found after uninstall: 1 table
    • wp_lpl_layers
  • Zombie WordPress options detected upon uninstall: 6 options
    • db_upgraded
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • widget_theysaidso_widget
    • widget_recent-comments

Smoke tests 75% 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)
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
The following issues need your attention
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/layered-pop/layered-pop.php:15

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
4 plugin tags: pop, pop-up, layered popup, popup

layered-pop/layered-pop.php 92% from 13 tests

"Layered Pop" version 0.11's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
The following require your attention:
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 165 characters long)

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
Good job! No executable or dangerous file extensions detected2,164 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP155151,257
CSS3123560
JavaScript2114346
HTML1001

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.47
Average class complexity139.00
▷ Minimum class complexity139.00
▷ Maximum class complexity139.00
Average method complexity6.75
▷ Minimum method complexity1.00
▷ Maximum method complexity47.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods24
▷ Static methods14.17%
▷ Public methods24100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants4100.00%
▷ Class constants00.00%
▷ Public constants00.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
9 compressed PNG files occupy 0.01MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/delete.png0.65KB0.67KB0.00%
images/edit.png0.68KB0.62KB▼ 9.99%
images/tooltip.png1.92KB1.21KB▼ 37.18%
images/preview.png0.51KB0.54KB0.00%
images/unblock.png0.61KB0.55KB▼ 8.84%