62% fixed-image-all-position-drag-and-drop

Code Review | Fixed image all Position drag and Drop

WordPress plugin Fixed image all Position drag and Drop scored62%from 54 tests.

About plugin

  • Plugin page: fixed-image-all-p...
  • Plugin version: 2.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.9
  • WordPress version: 6.3.1
  • First release: Dec 13, 2017
  • Latest release: Jun 2, 2018
  • Number of updates: 13
  • Update frequency: every 57.1 days
  • Top authors: createwebsite13 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

40+ active /1,157 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.15MB] [CPU: ▼3.70ms] Passed 4 tests

Server-side resources used by Fixed image all Position drag and Drop
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.81 ▲0.3448.32 ▲8.32
Dashboard /wp-admin3.45 ▲0.1048.59 ▼15.15
Posts /wp-admin/edit.php3.56 ▲0.2054.40 ▲6.97
Add New Post /wp-admin/post-new.php6.03 ▲0.1493.38 ▼9.22
Media Library /wp-admin/upload.php3.37 ▲0.1438.06 ▲2.59
Add Fixed Images /wp-admin/plugins.php?page=fixedbuttonsetting3.4139.07

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 16 new files
Database: 2 new tables, 7 new options
New tables
wp_Webleesbookmark
wp_Webleesbookmark_orders
New WordPress options
widget_recent-posts
db_upgraded
widget_theysaidso_widget
widget_recent-comments
can_compress_scripts
theysaidso_admin_options
WebleesBookmarkOptions

Browser metrics Passed 4 tests

This is an overview of browser requirements for Fixed image all Position drag and Drop
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,878 ▲13213.27 ▼1.102.07 ▼0.0542.81 ▼1.45
Dashboard /wp-admin2,210 ▲195.86 ▲1.00105.17 ▼13.4241.84 ▼4.51
Posts /wp-admin/edit.php2,090 ▲12.01 ▲0.0139.04 ▼1.0434.07 ▼0.95
Add New Post /wp-admin/post-new.php1,538 ▲1923.22 ▲0.12670.09 ▼7.3670.35 ▲11.57
Media Library /wp-admin/upload.php1,392 ▲14.25 ▲0.0593.45 ▼3.9641.68 ▲0.30
Add Fixed Images /wp-admin/plugins.php?page=fixedbuttonsetting1,1602.3936.8528.72

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • Zombie tables detected upon uninstall: 2 tables
    • wp_Webleesbookmark_orders
    • wp_Webleesbookmark
  • Zombie WordPress options detected upon uninstall: 7 options
    • widget_theysaidso_widget
    • db_upgraded
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_recent-posts
    • WebleesBookmarkOptions

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
These errors were triggered by the plugin
    • > GET request to /wp-admin/plugins.php?page=fixedbuttonsetting
    • > User deprecated in wp-includes/functions.php+5463
    Function screen_icon is deprecated since version 3.8.0 with no alternative available.
    • > GET request to /wp-admin/plugins.php?page=fixedbuttonsetting
    • > User deprecated in wp-includes/functions.php+5463
    Function get_screen_icon is deprecated since version 3.8.0 with no alternative available.

SRP 0% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
The following issues need your attention
  • 4× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/fixed-image-all-position-drag-and-drop/views/admin/edit.php
    • > /wp-content/plugins/fixed-image-all-position-drag-and-drop/views/admin/list.php
    • > /wp-content/plugins/fixed-image-all-position-drag-and-drop/views/index/list.php
    • > /wp-content/plugins/fixed-image-all-position-drag-and-drop/views/admin/setting.php
  • 6× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/fixed-image-all-position-drag-and-drop/listTable.php on line 3
    • > PHP Notice
      Trying to get property 'prefix' of non-object in wp-content/plugins/fixed-image-all-position-drag-and-drop/config.php on line 111
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_check_php_mysql_versions() in wp-content/plugins/fixed-image-all-position-drag-and-drop/config.php:134
    • > PHP Fatal error
      Uncaught Error: Class 'WebleesListTable' not found in wp-content/plugins/fixed-image-all-position-drag-and-drop/listBookmarkTable.php:3
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/fixed-image-all-position-drag-and-drop/listTable.php on line 3
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/fixed-image-all-position-drag-and-drop/listTable.php on line 3

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
5 plugin tags: fixed, images, positions, drag and drop, icons

fixed-image-all-position-drag-and-drop/weblees_wordpressbookmark.php 92% from 13 tests

The primary PHP file in "Fixed image all Position drag and Drop" version 2.1 is used by WordPress to initiate all plugin functionality
Please make the necessary changes and fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("fixed-image-all-position-drag-and-drop.php" instead of "weblees_wordpressbookmark.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
There were no executable files found in this plugin2,196 lines of code in 13 files:
LanguageFilesBlank linesComment linesLines of code
PHP113706662,020
CSS2340176

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.37
Average class complexity31.00
▷ Minimum class complexity5.00
▷ Maximum class complexity87.00
Average method complexity3.47
▷ Minimum method complexity1.00
▷ Maximum method complexity20.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods85
▷ Static methods11.18%
▷ Public methods85100.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
1 compressed PNG file occupies 0.00MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
public/admin/images/gray-grad.png0.21KB0.18KB▼ 11.74%