84% flash-show-and-hide-box

Code Review | Flash Show And Hide Box

WordPress plugin Flash Show And Hide Box scored84%from 54 tests.

About plugin

  • Plugin page: flash-show-and-hi...
  • Plugin version: 1.6
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.0-4.7.3
  • WordPress version: 6.3.1
  • First release: Oct 30, 2011
  • Latest release: Mar 27, 2017
  • Number of updates: 75
  • Update frequency: every 26.4 days
  • Top authors: lite3 (84%)litefeel (17.33%)

Code review

54 tests

User reviews

2 reviews

Install metrics

70+ active /15,234 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Installer ran successfully

Server metrics [RAM: ▼0.11MB] [CPU: ▼7.59ms] Passed 4 tests

Analyzing server-side resources used by Flash Show And Hide Box
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.87 ▼0.5922.09 ▼16.25
Dashboard /wp-admin3.35 ▲0.0547.96 ▼7.66
Posts /wp-admin/edit.php3.40 ▲0.0449.16 ▼1.91
Add New Post /wp-admin/post-new.php5.93 ▲0.0488.79 ▼4.55
Media Library /wp-admin/upload.php3.27 ▲0.0441.44 ▲3.11
Flash Show And Hide Box Options /wp-admin/options-general.php?page=flash-show-and-hide-box/flash-show-and-hide-box.php3.2432.25

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

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 13 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-posts
widget_theysaidso_widget
theysaidso_admin_options
can_compress_scripts
flashshowandhidebox_options
widget_recent-comments
db_upgraded

Browser metrics Passed 4 tests

An overview of browser requirements for Flash Show And Hide Box
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲5814.77 ▲0.472.13 ▲0.4643.23 ▲2.68
Dashboard /wp-admin2,210 ▲224.87 ▼0.03106.46 ▲0.0237.82 ▼7.28
Posts /wp-admin/edit.php2,093 ▲42.04 ▲0.0339.06 ▲2.7334.31 ▼4.16
Add New Post /wp-admin/post-new.php1,517 ▲317.80 ▲0.29689.48 ▲31.9663.52 ▲10.25
Media Library /wp-admin/upload.php1,392 ▲14.22 ▼0.0497.24 ▼23.6845.85 ▲1.23
Flash Show And Hide Box Options /wp-admin/options-general.php?page=flash-show-and-hide-box/flash-show-and-hide-box.php9182.1522.5422.98

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • Zombie WordPress options were found after uninstall: 7 options
    • db_upgraded
    • flashshowandhidebox_options
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments

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
Even though no errors were found, this is by no means an exhaustive test

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
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/flash-show-and-hide-box/flash-show-and-hide-box.php:24

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 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Attributes that need to be fixed:
  • Screenshots: These screenshots have no corresponding images in /assets: #1 (setting), #2 (hide flash state), #3 (show flash state)
You can look at the official readme.txt

flash-show-and-hide-box/flash-show-and-hide-box.php Passed 13 tests

"Flash Show And Hide Box" version 1.6's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
90 characters long description:
Flash Show And Hide Box lets we very convenient embed flash, and control it show and hide.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Success! There were no dangerous files found in this plugin322 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP13019194
Markdown257090
JavaScript10038

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.30
Average class complexity22.00
▷ Minimum class complexity22.00
▷ Maximum class complexity22.00
Average method complexity3.10
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods10
▷ Static methods00.00%
▷ Public methods10100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.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
4 PNG files occupy 0.03MB with 0.01MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-3.png8.68KB5.52KB▼ 36.38%
screenshot-1.png17.00KB8.88KB▼ 47.75%
img/donate-with-alipay.png4.09KB3.17KB▼ 22.44%
screenshot-2.png4.21KB2.52KB▼ 40.25%