72% flip-boxes

Code Review | Flipboxes - Ultimate Flipbox Styles

WordPress plugin Flipboxes - Ultimate Flipbox Styles scored72%from 54 tests.

About plugin

  • Plugin page: flip-boxes
  • Plugin version: 1.7.1
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5-6.3
  • WordPress version: 6.3.1
  • First release: Nov 17, 2017
  • Latest release: Aug 5, 2023
  • Number of updates: 50
  • Update frequency: every 41.7 days
  • Top authors: Narinder singh (100%)

Code review

54 tests

User reviews

93 reviews

Install metrics

7,000+ active /55,658 total downloads

Benchmarks

Plugin footprint 82% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
This plugin's installer ran successfully

Server metrics [RAM: ▲0.16MB] [CPU: ▼9.67ms] Passed 4 tests

An overview of server-side resources used by Flipboxes - Ultimate Flipbox Styles
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0542.36 ▼3.36
Dashboard /wp-admin3.50 ▲0.1653.90 ▼10.62
Posts /wp-admin/edit.php3.62 ▲0.2649.77 ▼2.49
Add New Post /wp-admin/post-new.php6.11 ▲0.2288.55 ▼22.21
Media Library /wp-admin/upload.php3.43 ▲0.2037.69 ▲0.61
All Flipboxes /wp-admin/edit.php?post_type=flipboxes4.2043.36
Add New /wp-admin/post-new.php?post_type=flipboxes4.7559.80

Server storage [IO: ▲4.00MB] [DB: ▲0.00MB] 67% from 3 tests

Analyzing filesystem and database footprints of this plugin
Please fix the following
  • Illegal file modification detected: 1 file (4.00KB) outside of "wp-content/plugins/flip-boxes/" and "wp-content/uploads/"
    • (new file) wp-content/mgd_mirror/mgd_maximinodotpy-gitdown-test-repository
Filesystem: 377 new files
Database: no new tables, 10 new options
New WordPress options
db_upgraded
can_compress_scripts
Flip-Boxes-installDate
Flip-Boxes-v
theysaidso_admin_options
widget_recent-comments
Flip-Boxes-ratingDiv
Flip-Boxes-type
widget_recent-posts
widget_theysaidso_widget

Browser metrics Passed 4 tests

Checking browser requirements for Flipboxes - Ultimate Flipbox Styles
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,842 ▲5613.62 ▼0.614.54 ▲2.5843.84 ▲0.09
Dashboard /wp-admin2,248 ▲484.85 ▼1.01111.49 ▲6.5442.31 ▲1.44
Posts /wp-admin/edit.php2,127 ▲242.02 ▼0.0135.15 ▼4.7334.46 ▼3.84
Add New Post /wp-admin/post-new.php1,549 ▲2317.61 ▲0.04667.83 ▼30.9455.83 ▲4.33
Media Library /wp-admin/upload.php1,427 ▲274.29 ▲0.13100.38 ▼2.6240.06 ▼5.59
All Flipboxes /wp-admin/edit.php?post_type=flipboxes1,1262.0039.1434.12
Add New /wp-admin/post-new.php?post_type=flipboxes7,3705.19174.9740.95

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
  • Zombie WordPress options detected upon uninstall: 10 options
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts
    • Flip-Boxes-ratingDiv
    • widget_recent-comments
    • Flip-Boxes-v
    • Flip-Boxes-installDate
    • can_compress_scripts
    • db_upgraded
    • Flip-Boxes-type

Smoke tests 25% from 4 tests

Server-side errors Passed 1 test

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

SRP 0% from 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
Please take a closer look at the following
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/flip-boxes/flipboxes.php
  • 56× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/flip-boxes/layouts/layout-2.php:4
    • > PHP Warning
      Use of undefined constant CFB_VERSION - assumed 'CFB_VERSION' (this will throw an Error in a future version of PHP) in wp-content/plugins/flip-boxes/feedback/admin-feedback-form.php on line 166
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/flip-boxes/layouts/layout-3.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Base' not found in wp-content/plugins/flip-boxes/admin/CMB2/includes/CMB2.php:21
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Text' not found in wp-content/plugins/flip-boxes/admin/CMB2/includes/types/CMB2_Type_File_Base.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Radio' not found in wp-content/plugins/flip-boxes/admin/CMB2/includes/types/CMB2_Type_Multicheck.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Taxonomy_Select' not found in wp-content/plugins/flip-boxes/admin/CMB2/includes/types/CMB2_Type_Taxonomy_Select_Hierarchical.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_REST_Controller' not found in wp-content/plugins/flip-boxes/admin/CMB2/includes/rest-api/CMB2_REST_Controller_Boxes.php:17
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Taxonomy_Base' not found in wp-content/plugins/flip-boxes/admin/CMB2/includes/types/CMB2_Type_Taxonomy_Select.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'CMB2_Type_Multi_Base' not found in wp-content/plugins/flip-boxes/admin/CMB2/includes/types/CMB2_Type_Select.php:13

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)
These are user-side errors you should fix
    • > GET request to /wp-admin/post-new.php?post_type=flipboxes
    • > Deprecation (warning) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1 1 Listener added for a synchronous 'DOMNodeInserted' DOM Mutation Event. This event type is deprecated (https://w3c.github.io/uievents/#legacy-event-types) and work is underway to remove it from this browser. Usage of this event listener will cause performance issues today, and represents a risk of future incompatibility. Consider using MutationObserver instead.

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
Attributes that require attention:
  • Screenshots: Please add descriptions for these screenshots #1, #2, #3, #4, #5 in flip-boxes/assets to your readme.txt
The official readme.txt is a good inspiration

flip-boxes/flipboxes.php 85% from 13 tests

This is the main PHP file of "Flipboxes - Ultimate Flipbox Styles" version 1.7.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
The following require your attention:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("flip-boxes.php" instead of "flipboxes.php")
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Good job! No executable or dangerous file extensions detected50,149 lines of code in 225 files:
LanguageFilesBlank linesComment linesLines of code
PO File12014,31518,50232,323
PHP712,2106,1397,847
CSS194631,2515,692
SVG1002,671
JavaScript144026011,616

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.48
Average class complexity19.76
▷ Minimum class complexity1.00
▷ Maximum class complexity186.00
Average method complexity3.34
▷ Minimum method complexity1.00
▷ Maximum method complexity31.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes75
▷ Abstract classes912.00%
▷ Concrete classes6688.00%
▷ Final classes00.00%
Methods605
▷ Static methods9615.87%
▷ Public methods50883.97%
▷ Protected methods9415.54%
▷ Private methods30.50%
Functions24
▷ Named functions24100.00%
▷ Anonymous functions00.00%
Constants13
▷ Global constants646.15%
▷ Class constants753.85%
▷ Public constants7100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
16 compressed PNG files occupy 0.07MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
admin/CMB2/images/ui-icons_888888_256x240.png5.23KB4.11KB▼ 21.49%
admin/CMB2/images/ui-icons_2e83ff_256x240.png4.27KB4.11KB▼ 3.78%
admin/CMB2/images/ui-icons_cd0a0a_256x240.png4.27KB4.11KB▼ 3.78%
admin/CMB2/images/ui-icons_222222_256x240.png4.27KB4.11KB▼ 3.78%
admin/CMB2/images/ui-bg_glass_65_ffffff_1x400.png0.10KB0.10KB▼ 5.71%