10% horizontal-tabs

Code Review | Horizontal Tabs Plugin

WordPress plugin Horizontal Tabs Plugin scored10%from 54 tests.

About plugin

  • Plugin page: horizontal-tabs
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-3.9
  • WordPress version: 6.3.1
  • First release: Aug 25, 2014
  • Latest release: Aug 25, 2014
  • Number of updates: 2
  • Update frequency: every 2.0 days
  • Top authors: pvs1984 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,196 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
These installer errors require your attention
  • The plugin did not install without errors
    • > Deprecated in wp-content/plugins/horizontal-tabs/horizontalTabs.php+14
    Methods with the same name as their class will not be constructors in a future version of PHP; horizontal_tabs_widget has a deprecated constructor

Server metrics [RAM: ▼1.91MB] [CPU: ▼51.68ms] Passed 4 tests

A check of server-side resources used by Horizontal Tabs Plugin
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /2.09 ▼1.375.13 ▼30.95
Dashboard /wp-admin2.11 ▼1.236.20 ▼49.12
Posts /wp-admin/edit.php2.11 ▼1.255.46 ▼42.90
Add New Post /wp-admin/post-new.php2.11 ▼3.786.15 ▼83.74
Media Library /wp-admin/upload.php2.11 ▼1.125.51 ▼27.97

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

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 24 new files
Database: no new tables, 7 new options
New WordPress options
theysaidso_admin_options
can_compress_scripts
widget_recent-comments
widget_horizontal_tabs_widget
db_upgraded
widget_recent-posts
widget_theysaidso_widget

Browser metrics Passed 4 tests

Horizontal Tabs Plugin: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,904 ▲14313.45 ▼1.209.45 ▲7.8942.30 ▲3.56
Dashboard /wp-admin2,198 ▲185.55 ▼0.0889.73 ▲2.2644.02 ▼1.47
Posts /wp-admin/edit.php2,100 ▼32.00 ▼0.0134.72 ▼3.3134.17 ▼1.97
Add New Post /wp-admin/post-new.php1,526 ▼023.61 ▼0.14603.37 ▼83.8550.12 ▼11.71
Media Library /wp-admin/upload.php1,400 ▼04.24 ▲0.0594.38 ▼6.0641.39 ▼4.93

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
You still need to fix the following
  • Uninstall procedure validation failed for this plugin
    • > Deprecated in wp-content/plugins/horizontal-tabs/horizontalTabs.php+14
    Methods with the same name as their class will not be constructors in a future version of PHP; horizontal_tabs_widget has a deprecated constructor
  • Zombie WordPress options detected upon uninstall: 7 options
    • can_compress_scripts
    • widget_horizontal_tabs_widget
    • widget_recent-comments
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • db_upgraded

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
Everything seems fine, however this is by no means an exhaustive test

SRP 50% 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
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/horizontal-tabs/horizontalTabs.php:14

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
These attributes need your attention:
  • Screenshots: Screenshot #1 (screenshot-1.jpeg .) image missing
You can take inspiration from this readme.txt

horizontal-tabs/horizontalTabs.php 92% from 13 tests

The main file in "Horizontal Tabs Plugin" v. 1.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
Please make the necessary changes and fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("horizontal-tabs.php" instead of "horizontalTabs.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Everything looks great! No dangerous files found in this plugin1,315 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
CSS337761,156
PHP14611159

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.18
Average class complexity15.00
▷ Minimum class complexity15.00
▷ Maximum class complexity15.00
Average method complexity2.75
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods8
▷ Static methods00.00%
▷ Public methods8100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
14 PNG files occupy 0.03MB with 0.02MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/ui-bg_diagonals-thick_18_b81900_40x40.png0.45KB0.15KB▼ 65.65%
images/ui-bg_glass_65_ffffff_1x400.png0.24KB0.09KB▼ 64.23%
images/ui-bg_flat_10_000000_40x100.png0.24KB0.08KB▼ 64.34%
images/ui-icons_222222_256x240.png6.84KB4.18KB▼ 38.88%
images/ui-bg_highlight-soft_100_eeeeee_1x100.png0.31KB0.14KB▼ 54.26%