73% cwd-3d-image-gallery

Code Review | CWD 3D Image Gallery

WordPress plugin CWD 3D Image Gallery scored73%from 54 tests.

About plugin

  • Plugin page: cwd-3d-image-gallery
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.9.1
  • WordPress version: 6.3.1
  • First release: May 30, 2014
  • Latest release: Jul 10, 2014
  • Number of updates: 4
  • Update frequency: every 10.3 days
  • Top authors: sent316 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,809 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.07MB] [CPU: ▲3.24ms] Passed 4 tests

This is a short check of server-side resources used by CWD 3D Image Gallery
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.54 ▲0.0845.55 ▲0.92
Dashboard /wp-admin3.39 ▲0.0560.92 ▼7.71
Posts /wp-admin/edit.php3.51 ▲0.1560.87 ▲5.10
Add New Post /wp-admin/post-new.php5.97 ▲0.08145.33 ▲42.17
Media Library /wp-admin/upload.php3.30 ▲0.0750.98 ▲14.63

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

Filesystem and database footprint
Please try to fix the following items
  • There were 1 file (4.00KB) illegally modified outside of "wp-content/plugins/cwd-3d-image-gallery/" and "wp-content/uploads/"
    • (new file) wp-content/mgd_mirror/mgd_maximinodotpy-gitdown-test-repository
Filesystem: 28 new files
Database: 2 new tables, 6 new options
New tables
wp_image_3d_gallery
wp_image_3d
New WordPress options
widget_recent-posts
can_compress_scripts
widget_recent-comments
theysaidso_admin_options
widget_theysaidso_widget
db_upgraded

Browser metrics Passed 4 tests

CWD 3D Image Gallery: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,230 ▲48415.70 ▲1.5613.24 ▲11.4746.51 ▲2.40
Dashboard /wp-admin2,377 ▲1746.40 ▲0.52132.70 ▲26.91105.10 ▲61.14
Posts /wp-admin/edit.php2,292 ▲1923.43 ▲1.3984.55 ▲40.5188.37 ▲49.95
Add New Post /wp-admin/post-new.php1,562 ▲721.01 ▼1.68823.06 ▲142.5942.34 ▼14.34
Media Library /wp-admin/upload.php1,425 ▲284.30 ▲0.02123.44 ▲19.14129.79 ▲84.32

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
Please fix the following items
  • The uninstall procedure failed, leaving 2 tables in the database
    • wp_image_3d
    • wp_image_3d_gallery
  • This plugin does not fully uninstall, leaving 6 options in the database
    • can_compress_scripts
    • widget_recent-posts
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-comments
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting 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 | 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 items
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/cwd-3d-image-gallery/index.php:47

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

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
These attributes need your attention:
  • Screenshots: Add images for these screenshots: #1 (**Dahboard** - CWD 3D Image Gallery plugin dashboard), #2 (**Settings** - CWD 3D Image Gallery Settings), #3 (**Horizontal** - Horizontal Animation), #4 (**Vertical** - Vertical Animation)
The official readme.txt is a good inspiration

cwd-3d-image-gallery/index.php 92% from 13 tests

The primary PHP file in "CWD 3D Image Gallery" version 1.0 is used by WordPress to initiate all plugin functionality
The following require your attention:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("cwd-3d-image-gallery.php" instead of "index.php")

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 detected1,347 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript3335222611
PHP11829449
CSS1476287

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.17
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions11
▷ Named functions11100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
13 PNG files occupy 1.05MB with 0.70MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/settings.png3.04KB0.46KB▼ 85.02%
images/options.png1.82KB0.69KB▼ 61.99%
images/close-button.png1.44KB1.38KB▼ 4.34%
images/fancy_deboss.png3.61KB0.25KB▼ 93.02%
images/delete.png2.95KB0.32KB▼ 89.29%