89% meta-box

Code Review | Meta Box - WordPress Custom Fields Framework

WordPress plugin Meta Box - WordPress Custom Fields Framework scored89%from 54 tests.

About plugin

  • Plugin page: meta-box
  • Plugin version: 5.9.0
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.9-6.4.1
  • WordPress version: 6.3.1
  • First release: Nov 7, 2011
  • Latest release: Nov 22, 2023
  • Number of updates: 348
  • Update frequency: every 12.7 days
  • Top authors: rilwis (100%)

Code review

54 tests

User reviews

145 reviews

Install metrics

700,000+ active /15,927,082 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
This plugin's installer ran successfully

Server metrics [RAM: ▲0.36MB] [CPU: ▼3.14ms] Passed 4 tests

Analyzing server-side resources used by Meta Box - WordPress Custom Fields Framework
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.86 ▲0.3945.68 ▲1.78
Dashboard /wp-admin3.72 ▲0.3752.39 ▼12.96
Posts /wp-admin/edit.php3.77 ▲0.4149.36 ▲1.53
Add New Post /wp-admin/post-new.php6.24 ▲0.3598.46 ▼2.90
Media Library /wp-admin/upload.php3.58 ▲0.3536.17 ▲2.05
Dashboard /wp-admin/plugins.php?page=meta-box3.6738.96

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

Input-output and database impact of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 332 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
widget_theysaidso_widget
widget_recent-comments
can_compress_scripts
theysaidso_admin_options
db_upgraded

Browser metrics Passed 4 tests

Meta Box - WordPress Custom Fields Framework: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,790 ▲4314.27 ▼0.081.72 ▲0.1043.69 ▲0.01
Dashboard /wp-admin2,195 ▲155.52 ▼0.1083.07 ▼16.8535.99 ▼10.88
Posts /wp-admin/edit.php2,100 ▲32.01 ▼0.0035.47 ▼0.1938.31 ▲4.87
Add New Post /wp-admin/post-new.php1,526 ▼923.24 ▼2.10667.01 ▲31.1548.54 ▼22.87
Media Library /wp-admin/upload.php1,400 ▼34.13 ▼0.0995.91 ▼8.1641.12 ▼3.18
Dashboard /wp-admin/plugins.php?page=meta-box1,7498.95283.6267.95

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
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-posts
    • db_upgraded
    • widget_recent-comments
    • can_compress_scripts

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP Passed 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
No output text or server-side errors detected on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
These attributes need your attention:
  • Screenshots: Add descriptions for screenshots #2, #3, #4, #5, #6 in meta-box/assets to your readme.txt
  • Tags: Please reduce the number of tags, currently 28 tag instead of maximum 10
You can take inspiration from this readme.txt

meta-box/meta-box.php 92% from 13 tests

Analyzing the main PHP file in "Meta Box - WordPress Custom Fields Framework" version 5.9.0
The following require your attention:
  • Domain Path: The domain path is invalid: folder "/languages/" does not exist

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
Good job! No executable or dangerous file extensions detected75,099 lines of code in 315 files:
LanguageFilesBlank linesComment linesLines of code
JSON20059,301
JavaScript1581,1361,4286,665
PHP1131,2993,1316,617
CSS411741172,511
SVG1005

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.34
Average class complexity8.75
▷ Minimum class complexity1.00
▷ Maximum class complexity67.00
Average method complexity2.48
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces8
Interfaces1
Traits0
Classes91
▷ Abstract classes66.59%
▷ Concrete classes8593.41%
▷ Final classes00.00%
Methods482
▷ Static methods32066.39%
▷ Public methods41686.31%
▷ Protected methods347.05%
▷ Private methods326.64%
Functions18
▷ Named functions1161.11%
▷ Anonymous functions738.89%
Constants7
▷ Global constants685.71%
▷ Class constants114.29%
▷ Public constants1100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
14 compressed PNG files occupy 0.03MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
img/jqueryui/ui-bg_highlight-soft_75_cccccc_1x100.png0.10KB0.17KB0.00%
img/jqueryui/ui-icons_454545_256x240.png4.27KB4.11KB▼ 3.78%
img/jqueryui/ui-icons_2e83ff_256x240.png4.27KB4.11KB▼ 3.78%
img/jqueryui/ui-bg_glass_95_fef1ec_1x400.png0.12KB0.14KB0.00%
img/jqueryui/ui-icons_222222_256x240.png4.27KB4.11KB▼ 3.78%