77% tabs-pro

Code Review | Tab Ultimate

WordPress plugin Tab Ultimate scored77%from 54 tests.

About plugin

  • Plugin page: tabs-pro
  • Plugin version: 1.4
  • PHP version: 7.4.16
  • WordPress compatibility: 3.8-6.3.2
  • WordPress version: 6.3.1
  • First release: Jul 2, 2015
  • Latest release: Oct 21, 2023
  • Number of updates: 38
  • Update frequency: every 79.9 days
  • Top authors: themepoints (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

2,000+ active /7,923 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.51MB] [CPU: ▲1.98ms] Passed 4 tests

Analyzing server-side resources used by Tab Ultimate
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /4.00 ▲0.5342.33 ▲3.68
Dashboard /wp-admin3.85 ▲0.5050.55 ▼3.86
Posts /wp-admin/edit.php3.90 ▲0.5446.80 ▲2.66
Add New Post /wp-admin/post-new.php6.44 ▲0.55100.83 ▲5.43
Media Library /wp-admin/upload.php3.71 ▲0.4839.47 ▲7.06
Tabs Free /wp-admin/edit.php?post_type=tp_tab_pro3.8239.49
Add New Tab /wp-admin/post-new.php?post_type=tp_tab_pro3.9553.16

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 72 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
db_upgraded
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-comments
widget_recent-posts

Browser metrics Passed 4 tests

A check of browser resources used by Tab Ultimate
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,927 ▲16613.83 ▼0.528.43 ▲6.8445.25 ▲4.46
Dashboard /wp-admin2,220 ▲405.59 ▼0.0882.07 ▼2.7239.18 ▼2.33
Posts /wp-admin/edit.php2,131 ▲282.01 ▼0.0336.27 ▲1.0032.02 ▼3.79
Add New Post /wp-admin/post-new.php1,565 ▲3923.56 ▲0.54578.34 ▼105.8131.70 ▼27.59
Media Library /wp-admin/upload.php1,434 ▲314.16 ▼0.0896.05 ▼4.6241.64 ▼3.70
Tabs Free /wp-admin/edit.php?post_type=tp_tab_pro1,1252.2634.4330.65
Add New Tab /wp-admin/post-new.php?post_type=tp_tab_pro5,5165.82127.1240.02

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-comments
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts

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 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
The following issues need your attention
  • 5× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/tabs-pro/metabox/example-functions.php:104
    • > PHP Warning
      Use of undefined constant WP_CONTENT_URL - assumed 'WP_CONTENT_URL' (this will throw an Error in a future version of PHP) in wp-content/plugins/tabs-pro/metabox/custom-meta-boxes-free.php on line 46
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/tabs-pro/metabox/classes.fields.php:581
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/tabs-pro/metabox/classes.fields.php:581
    • > PHP Warning
      Use of undefined constant WP_CONTENT_DIR - assumed 'WP_CONTENT_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/tabs-pro/metabox/custom-meta-boxes-free.php on line 46

User-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
There are user-side issues you should fix
    • > GET request to /wp-admin/edit.php?post_type=tp_tab_pro
    • > Console-api (warning) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1 1:28609 "jQuery.Deferred exception: jQuery(...).sortable is not a function" "TypeError: jQuery(...).sortable is not a function\n at HTMLDocument.\u003Canonymous> (/wp-content/plugins/tabs-pro/admin/js/color-picker.js?ver=6.3.1:2:25)\n at e (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1:2:26990)\n at t (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1:2:27292)" undefined
    • > GET request to /wp-admin/edit.php?post_type=tp_tab_pro
    • > Javascript (severe) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1 1:28721 Uncaught TypeError: jQuery(...).sortable is not a function

Optimizations

Plugin configuration 86% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
9 plugin tags: tabs plugin jquery, tab, tabs short-code, tabs plugin, tabs...

tabs-pro/tptabs-ultimate.php 69% from 13 tests

The entry point to "Tab Ultimate" version 1.4 is a PHP file that has certain tags in its header comment area
The following require your attention:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("tabs-pro.php" instead of "tptabs-ultimate.php")
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6
  • Domain Path: The domain path folder was not found ("/languages")
  • Description: The description should be shorter than 140 characters (currently 149 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Good job! No executable or dangerous file extensions detected13,833 lines of code in 42 files:
LanguageFilesBlank linesComment linesLines of code
CSS193021815,633
JavaScript138235223,205
SVG1002,671
PHP88133752,292
PO File181032

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.38
Average class complexity9.00
▷ Minimum class complexity1.00
▷ Maximum class complexity61.00
Average method complexity2.91
▷ Minimum method complexity1.00
▷ Maximum method complexity9.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes22
▷ Abstract classes14.55%
▷ Concrete classes2195.45%
▷ Final classes00.00%
Methods92
▷ Static methods22.17%
▷ Public methods8895.65%
▷ Protected methods11.09%
▷ Private methods33.26%
Functions30
▷ Named functions30100.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants4100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
18 PNG files occupy 0.04MB with 0.02MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
metabox/images/cmb-icon-remove.png1.00KB0.14KB▼ 85.64%
metabox/images/cmb-icon-remove@2x.png1.14KB0.23KB▼ 79.47%
metabox/css/vendor/jquery-ui/images/ui-icons_2e83ff_256x240.png4.44KB4.17KB▼ 6.02%
metabox/css/vendor/jquery-ui/images/ui-bg_flat_75_ffffff_40x100.png0.20KB0.08KB▼ 58.17%
metabox/css/vendor/jquery-ui/images/ui-icons_888888_256x240.png6.83KB4.17KB▼ 38.92%