78% splash-header

Code Review | Splash Header

WordPress plugin Splash Header scored78%from 54 tests.

About plugin

  • Plugin page: splash-header
  • Plugin version: 2.1.3
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Oct 20, 2015
  • Latest release: Nov 16, 2023
  • Number of updates: 98
  • Update frequency: every 30.1 days
  • Top authors: kareemzok (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /5,397 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Install script ran successfully

Server metrics [RAM: ▲0.12MB] [CPU: ▼4.60ms] Passed 4 tests

An overview of server-side resources used by Splash Header
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.56 ▲0.1042.47 ▲1.87
Dashboard /wp-admin3.51 ▲0.1747.96 ▼12.14
Posts /wp-admin/edit.php3.52 ▲0.1646.33 ▼1.37
Add New Post /wp-admin/post-new.php5.99 ▲0.1097.11 ▼6.77
Media Library /wp-admin/upload.php3.33 ▲0.1040.90 ▲7.58
Design Settings /wp-admin/admin.php?page=splash-header&tab=design3.4535.19
General /wp-admin/admin.php?page=splash-header3.3335.32
Advanced Settings /wp-admin/admin.php?page=splash-header&tab=advancedsettings3.3934.18
Plugin Settings /wp-admin/admin.php?page=splash-header&tab=homepage3.3938.48

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

A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 73 new files
Database: no new tables, 110 new options
New WordPress options
sh_font_icon_6
sh_time_font_weight
sh_title_text_align
sh_title_font_style
sh_link_url_3
sh_link_title_1
sh_link_title_color_4
sh_title
sh_show_links_2
sh_link_open_2
...

Browser metrics Passed 4 tests

An overview of browser requirements for Splash Header
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,873 ▲12614.27 ▼0.051.89 ▲0.1738.19 ▼6.00
Dashboard /wp-admin2,273 ▲955.54 ▼0.1899.43 ▼15.7587.48 ▲43.65
Posts /wp-admin/edit.php2,137 ▲371.98 ▲0.0437.29 ▼5.8133.43 ▼3.86
Add New Post /wp-admin/post-new.php1,717 ▲19124.57 ▲1.70705.47 ▲56.2160.54 ▲3.15
Media Library /wp-admin/upload.php1,434 ▲314.27 ▼0.0099.23 ▼3.0176.33 ▲30.97
Design Settings /wp-admin/admin.php?page=splash-header&tab=design3,92910.77256.01104.00
General /wp-admin/admin.php?page=splash-header1,1318.83177.5054.75
Advanced Settings /wp-admin/admin.php?page=splash-header&tab=advancedsettings2,0919.30162.6458.82
Plugin Settings /wp-admin/admin.php?page=splash-header&tab=homepage1,8858.85133.4557.17

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
You still need to fix the following
  • The uninstall procedure has failed, leaving 110 options in the database
    • sh_link_title_color_3
    • sh_link_text_align_4
    • sh_date_position
    • sh_font_icon_5
    • sh_link_font_decoration_6
    • sh_date_font_style
    • theysaidso_admin_options
    • sh_title_color
    • sh_link_text_align_2
    • sh_link_url_2
    • ...

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Good news, no errors were detected

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
Almost there! Just fix the following items
  • 6× 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/splash-header/splash-header-admin-form.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/splash-header/includes/splash-header-constants.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/splash-header/tabs/splash-header-advanced-tab.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/splash-header/tabs/splash-header-design-tab.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/splash-header/tabs/splash-header-settings-tab.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/splash-header/tabs/splash-header-general-tab.php:1

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Please take a look at the following user-side issues
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=splash-header&tab=homepage
    • > Security (warning) in unknown
    security - Error with Permissions-Policy header: Unrecognized feature: 'ambient-light-sensor'.
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=splash-header&tab=homepage
    • > Security (warning) in unknown
    security - Error with Permissions-Policy header: Unrecognized feature: 'bluetooth'.

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
Please fix the following attributes:
  • Screenshots: These screenshots need descriptions #2, #3, #4, #5, #6 in splash-header/assets to your readme.txt
You can look at the official readme.txt

splash-header/splash-header-admin.php 92% from 13 tests

The primary PHP file in "Splash Header" version 2.1.3 is used by WordPress to initiate all plugin functionality
It is important to fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("splash-header.php" instead of "splash-header-admin.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
No dangerous file extensions were detected9,609 lines of code in 27 files:
LanguageFilesBlank linesComment linesLines of code
CSS746204,813
SVG1002,671
PHP127902261,522
PO File2236240503
JavaScript220380
XML20019
HTML1001

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity46.50
▷ Minimum class complexity1.00
▷ Maximum class complexity93.00
Average method complexity46.50
▷ Minimum method complexity1.00
▷ Maximum method complexity93.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes4
▷ Abstract classes00.00%
▷ Concrete classes4100.00%
▷ Final classes00.00%
Methods4
▷ Static methods4100.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions29
▷ Named functions29100.00%
▷ Anonymous functions00.00%
Constants7
▷ Global constants7100.00%
▷ Class constants00.00%
▷ Public constants00.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
8 PNG files occupy 0.09MB with 0.05MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/no-icon.png1.60KB0.77KB▼ 52.19%
includes/assets/img/sociabatt.png32.94KB6.46KB▼ 80.40%
includes/assets/no-icon.png1.60KB0.77KB▼ 52.19%
includes/assets/img/survey.png9.68KB8.51KB▼ 12.10%
assets/img/sociabatt.png32.94KB6.46KB▼ 80.40%