72% pagelayer

Code Review | Page Builder: Pagelayer - Drag and Drop website builder

WordPress plugin Page Builder: Pagelayer - Drag and Drop website builder scored72%from 54 tests.

About plugin

  • Plugin page: pagelayer
  • Plugin version: 1.7.8
  • PHP compatiblity: 5.5+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-6.3
  • WordPress version: 6.3.1
  • First release: Apr 8, 2019
  • Latest release: Sep 22, 2023
  • Number of updates: 189
  • Update frequency: every 8.6 days
  • Top authors: pagelayer (100%)

Code review

54 tests

User reviews

86 reviews

Install metrics

200,000+ active /5,288,639 total downloads

Benchmarks

Plugin footprint 82% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully

Server metrics [RAM: ▲1.13MB] [CPU: ▲8.67ms] Passed 4 tests

An overview of server-side resources used by Page Builder: Pagelayer - Drag and Drop website builder
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /4.62 ▲1.1656.91 ▲13.77
Dashboard /wp-admin4.45 ▲1.1059.96 ▼5.46
Posts /wp-admin/edit.php4.50 ▲1.1459.11 ▲9.99
Add New Post /wp-admin/post-new.php7.03 ▲1.14109.20 ▲16.39
Media Library /wp-admin/upload.php4.37 ▲1.1458.68 ▲20.70
Meta Settings /wp-admin/admin.php?page=pagelayer_meta_setting4.3447.88
Theme Templates /wp-admin/edit.php?post_type=pagelayer-template4.4149.77
License /wp-admin/admin.php?page=pagelayer_license4.5745.51
Settings /wp-admin/admin.php?page=pagelayer4.5543.60
Replace media /wp-admin/admin.php?page=pagelayer_replace_media4.3042.75
Add New Template /wp-admin/admin.php?page=pagelayer_template_wizard4.2744.64
Website Settings /wp-admin/admin.php?page=pagelayer_website_settings4.6660.79
Getting Started /wp-admin/admin.php?page=pagelayer_getting_started4.3146.07

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

A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 162 new files
Database: no new tables, 10 new options
New WordPress options
pagelayer_version
widget_recent-comments
widget_recent-posts
theysaidso_admin_options
db_upgraded
pagelayer_promo_time
pagelayer_getting_started
widget_theysaidso_widget
can_compress_scripts
pagelayer_options

Browser metrics 75% from 4 tests

This is an overview of browser requirements for Page Builder: Pagelayer - Drag and Drop website builder
It is time to focus on the following
  • Nodes: Limit the number of DOM nodes under 25,000 (currently 39,178 on /wp-admin/admin.php?page=pagelayer_website_settings)
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,861 ▲7513.22 ▼1.151.97 ▼0.4241.53 ▼2.22
Dashboard /wp-admin2,252 ▲495.85 ▼0.05113.82 ▲4.0780.79 ▲32.28
Posts /wp-admin/edit.php2,160 ▲602.01 ▼0.0236.45 ▼1.2534.15 ▼2.47
Add New Post /wp-admin/post-new.php1,741 ▲19324.84 ▲1.72748.13 ▲84.7855.29 ▲1.88
Media Library /wp-admin/upload.php1,446 ▲434.16 ▼0.16119.80 ▲14.8155.97 ▲10.59
Meta Settings /wp-admin/admin.php?page=pagelayer_meta_setting8412.0427.1025.95
Theme Templates /wp-admin/edit.php?post_type=pagelayer-template1,1761.9734.3538.30
License /wp-admin/admin.php?page=pagelayer_license1,1582.2329.4945.55
Settings /wp-admin/admin.php?page=pagelayer1,4161.8130.9637.92
Replace media /wp-admin/admin.php?page=pagelayer_replace_media7251.167.5219.17
Add New Template /wp-admin/admin.php?page=pagelayer_template_wizard8632.0929.1031.96
Website Settings /wp-admin/admin.php?page=pagelayer_website_settings39,1782.28409.92146.48
Getting Started /wp-admin/admin.php?page=pagelayer_getting_started1,5999.21270.8391.11

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • The uninstall procedure has failed, leaving 10 options in the database
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts
    • can_compress_scripts
    • pagelayer_options
    • pagelayer_promo_time
    • widget_recent-comments
    • pagelayer_getting_started
    • pagelayer_version

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Almost there, just fix the following server-side errors
    • > GET request to /wp-admin/admin.php?page=pagelayer_meta_setting
    • > Notice in wp-content/plugins/pagelayer/main/post_metas.php+31
    Undefined index: post
    • > GET request to /wp-admin/admin.php?page=pagelayer_replace_media
    • > Notice in wp-content/plugins/pagelayer/main/replace-media.php+36
    Undefined index: id
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: body
  • 1881 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Trying to access array offset on value of type null
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: body_tablet
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: body_mobile
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: header
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: header_tablet
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: header_mobile
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: main
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: main_tablet
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: main_mobile
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: footer
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: footer_tablet
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: footer_mobile
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: entry-header
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: entry-header_tablet
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: entry-header_mobile
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: entry-content
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: entry-content_tablet
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: entry-content_mobile
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: entry-footer
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: entry-footer_tablet
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: entry-footer_mobile
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: p
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: p_tablet
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: p_mobile
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: aside
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: aside_tablet
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: aside_mobile
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: a
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: a_tablet
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: a_mobile
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: a-hover
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: a-hover_tablet
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: a-hover_mobile
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: h1
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: h1_tablet
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: h1_mobile
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: h2
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: h2_tablet
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: h2_mobile
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: h3
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: h3_tablet
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: h3_mobile
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: h4
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: h4_tablet
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: h4_mobile
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: h5
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: h5_tablet
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: h5_mobile
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: h6
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: h6_tablet
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: h6_mobile
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: b
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: b_tablet
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: b_mobile
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: i
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: i_tablet
  • 33 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=pagelayer_website_settings
    • > Notice in wp-content/plugins/pagelayer/main/website.php+669
    Undefined index: i_mobile

SRP 0% 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
Please fix the following items
  • 23× PHP files output non-empty strings when accessed directly via GET requests (only 10 are shown):
    • > /wp-content/plugins/pagelayer/main/nav_walker.php
    • > /wp-content/plugins/pagelayer/main/shortcodes.php
    • > /wp-content/plugins/pagelayer/main/customizer.php
    • > /wp-content/plugins/pagelayer/main/post_metas.php
    • > /wp-content/plugins/pagelayer/main/template.php
    • > /wp-content/plugins/pagelayer/main/customizer-controls.php
    • > /wp-content/plugins/pagelayer/main/license.php
    • > /wp-content/plugins/pagelayer/main/functions.php
    • > /wp-content/plugins/pagelayer/main/getting_started.php
    • > /wp-content/plugins/pagelayer/main/import.php
  • 9× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Warning
      file_get_contents(wp-content/plugins/pagelayer/js/premium.js): failed to open stream: No such file or directory in /var/www/wordpress/wp-content/plugins/pagelayer/js/givejs.php on line 94
    • > PHP Fatal error
      Uncaught Error: Interface 'pagelayerQuery\\IQuery' not found in wp-content/plugins/pagelayer/lib/pquery/pQuery.php:15
    • > PHP Warning
      file_get_contents(wp-content/plugins/pagelayer/js/premium-frontend.js): failed to open stream: No such file or directory in /var/www/wordpress/wp-content/plugins/pagelayer/js/givejs.php on line 94
    • > PHP Fatal error
      Uncaught Error: Class 'pagelayerQuery\\HtmlParserBase' not found in wp-content/plugins/pagelayer/lib/pquery/gan_xml2array.php:15
    • > PHP Fatal error
      Uncaught Error: Class 'pagelayerQuery\\TokenizerBase' not found in wp-content/plugins/pagelayer/lib/pquery/gan_parser_html.php:18
    • > PHP Warning
      file_get_contents(wp-content/plugins/pagelayer/css/chartist.min.css): failed to open stream: No such file or directory in /var/www/wordpress/wp-content/plugins/pagelayer/css/givecss.php on line 85
    • > PHP Fatal error
      Uncaught Error: Class 'pagelayerQuery\\TokenizerBase' not found in wp-content/plugins/pagelayer/lib/pquery/gan_selector_html.php:15
    • > PHP Fatal error
      Uncaught Error: Interface 'pagelayerQuery\\IQuery' not found in wp-content/plugins/pagelayer/lib/pquery/gan_node_html.php:17
    • > PHP Warning
      file_get_contents(wp-content/plugins/pagelayer/css/premium-frontend.css): failed to open stream: No such file or directory in /var/www/wordpress/wp-content/plugins/pagelayer/css/givecss.php on line 85

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
These attributes need your attention:
  • Tags: There are too many tags (62 tag instead of maximum 10)
You can look at the official readme.txt

pagelayer/pagelayer.php Passed 13 tests

The main file in "Page Builder: Pagelayer - Drag and Drop website builder" v. 1.7.8 serves as a complement to information provided in readme.txt and as the entry point to the plugin
97 characters long description:
PageLayer is a WordPress page builder plugin. Its very easy to use and very light on the browser.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
There were no executable files found in this plugin69,903 lines of code in 115 files:
LanguageFilesBlank linesComment linesLines of code
PHP355,0656,21025,292
JavaScript275,6642,47917,762
CSS162,54445014,949
SVG33019,826
JSON3002,040
Markdown115034

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.50
Average class complexity32.86
▷ Minimum class complexity1.00
▷ Maximum class complexity311.00
Average method complexity3.94
▷ Minimum method complexity1.00
▷ Maximum method complexity83.00
Code structure
Namespaces1
Interfaces1
Traits0
Classes28
▷ Abstract classes00.00%
▷ Concrete classes28100.00%
▷ Final classes00.00%
Methods335
▷ Static methods41.19%
▷ Public methods26579.10%
▷ Protected methods7020.90%
▷ Private methods00.00%
Functions365
▷ Named functions34193.42%
▷ Anonymous functions246.58%
Constants72
▷ Global constants2129.17%
▷ Class constants5170.83%
▷ Public constants51100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
21 PNG files occupy 0.08MB with 0.03MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/color-picker-transparency-grid.png2.58KB2.80KB0.00%
images/no_screenshot.png9.75KB5.69KB▼ 41.64%
images/pagelayer-logo-256.png6.69KB3.61KB▼ 46.08%
images/splash.png3.86KB2.59KB▼ 32.82%
images/wpcentral_product.png9.33KB3.89KB▼ 58.27%