10% simple-side-tab

Code Review | Simple Side Tab

WordPress plugin Simple Side Tab scored10%from 54 tests.

About plugin

  • Plugin page: simple-side-tab
  • Plugin version: 2.1.11
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.2-6.4
  • WordPress version: 6.3.1
  • First release: Aug 12, 2012
  • Latest release: Nov 19, 2023
  • Number of updates: 47
  • Update frequency: every 87.6 days
  • Top authors: srumery (100%)

Code review

54 tests

User reviews

21 reviews

Install metrics

10,000+ active /164,606 total downloads

Benchmarks

Plugin footprint 58% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Please fix the following installer errors
  • Install procedure validation failed for this plugin
    • > Notice in wp-content/plugins/simple-side-tab/includes/class-simple-side-tab-options.php+58
    Trying to access array offset on value of type bool

Server metrics [RAM: ▲0.02MB] [CPU: ▼4.21ms] Passed 4 tests

An overview of server-side resources used by Simple Side Tab
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0335.99 ▼3.39
Dashboard /wp-admin3.33 ▲0.0244.58 ▼6.57
Posts /wp-admin/edit.php3.38 ▲0.0252.56 ▲8.92
Add New Post /wp-admin/post-new.php5.91 ▲0.0287.88 ▼7.99
Media Library /wp-admin/upload.php3.25 ▲0.0232.01 ▲1.10
Simple Side Tab /wp-admin/options-general.php?page=rum_simple_side_tab3.2843.71

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 20 new files
Database: no new tables, 7 new options
New WordPress options
can_compress_scripts
rum_sst_plugin_options
db_upgraded
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-posts
widget_recent-comments

Browser metrics Passed 4 tests

Checking browser requirements for Simple Side Tab
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,794 ▲4714.22 ▲0.051.48 ▼0.1841.01 ▼1.98
Dashboard /wp-admin2,199 ▲285.60 ▼0.0897.68 ▼1.9339.98 ▼4.43
Posts /wp-admin/edit.php2,104 ▲12.01 ▼0.0037.56 ▲1.2535.50 ▼0.70
Add New Post /wp-admin/post-new.php1,538 ▲325.20 ▲1.84591.75 ▼105.4359.71 ▲5.01
Media Library /wp-admin/upload.php1,401 ▼24.20 ▼0.0198.61 ▼3.2241.45 ▼3.03
Simple Side Tab /wp-admin/options-general.php?page=rum_simple_side_tab1,3282.4769.2636.23

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • db_upgraded
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 0% 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
Almost there! Just fix the following items
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/simple-side-tab/admin/partials/sidebar.php
  • 3× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Warning
      Use of undefined constant SIMPLE_SIDE_TAB_VERSION - assumed 'SIMPLE_SIDE_TAB_VERSION' (this will throw an Error in a future version of PHP) in wp-content/plugins/simple-side-tab/public/partials/dynamic-css.php on line 15
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/simple-side-tab/admin/partials/settings-page.php:19
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/simple-side-tab/public/partials/dynamic-css.php:17

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
These attributes need to be fixed: You can look at the official readme.txt

simple-side-tab/simple_side_tab.php 92% from 13 tests

This is the main PHP file of "Simple Side Tab" version 2.1.11, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please make the necessary changes and fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("simple-side-tab.php" instead of "simple_side_tab.php")

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 detected558 lines of code in 16 files:
LanguageFilesBlank linesComment linesLines of code
PHP14325581488
CSS11065
JavaScript1215

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.15
Average class complexity3.88
▷ Minimum class complexity1.00
▷ Maximum class complexity9.00
Average method complexity1.55
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes8
▷ Abstract classes00.00%
▷ Concrete classes8100.00%
▷ Final classes00.00%
Methods42
▷ Static methods37.14%
▷ Public methods3788.10%
▷ Protected methods00.00%
▷ Private methods511.90%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants6
▷ Global constants6100.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
No PNG images were found in this plugin