68% ishortcode

Code Review | WP短代码 ishortcode

WordPress plugin WP短代码 ishortcode scored68%from 54 tests.

About plugin

  • Plugin page: ishortcode
  • Plugin version: 3...
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5.1-3.8
  • WordPress version: 6.3.1
  • First release: Jan 2, 2014
  • Latest release: Jan 5, 2014
  • Number of updates: 6
  • Update frequency: every 0.7 days
  • Top authors: ihome123 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /810 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▼1.92MB] [CPU: ▼52.83ms] Passed 4 tests

Analyzing server-side resources used by WP短代码 ishortcode
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.07 ▼1.399.72 ▼29.94
Dashboard /wp-admin2.09 ▼1.2511.95 ▼51.43
Posts /wp-admin/edit.php2.09 ▼1.266.61 ▼39.19
Add New Post /wp-admin/post-new.php2.09 ▼3.795.91 ▼90.74
Media Library /wp-admin/upload.php2.09 ▼1.146.71 ▼29.34
短代码提示 /wp-admin/tools.php?page=shortcode_page2.095.71

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 24 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
db_upgraded
can_compress_scripts
widget_recent-posts
theysaidso_admin_options
widget_theysaidso_widget

Browser metrics Passed 4 tests

This is an overview of browser requirements for WP短代码 ishortcode
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,838 ▲9213.18 ▼1.202.23 ▲0.6039.00 ▼5.51
Dashboard /wp-admin2,209 ▲214.85 ▼1.05106.65 ▼6.5546.20 ▲1.12
Posts /wp-admin/edit.php2,095 ▲62.06 ▲0.0538.86 ▲3.9340.42 ▲9.59
Add New Post /wp-admin/post-new.php1,528 ▲918.24 ▼4.84616.33 ▼72.1050.96 ▼10.70
Media Library /wp-admin/upload.php1,391 ▼04.25 ▲0.0192.47 ▼5.0443.62 ▲1.57
短代码提示 /wp-admin/tools.php?page=shortcode_page7972.1824.0658.33

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
The following items require your attention
  • The plugin did not uninstall gracefully
    • > User notice in wp-includes/functions.php+5905
    Function wp_enqueue_style was called incorrectly. Scripts and styles should not be registered or enqueued until the wp_enqueue_scripts, admin_enqueue_scripts, or login_enqueue_scripts hooks. This notice was triggered by the ishortcode handle. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-comments
    • can_compress_scripts
    • db_upgraded
    • widget_recent-posts
    • widget_theysaidso_widget
    • theysaidso_admin_options

Smoke tests 50% 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)
Please fix the following server-side errors
    • > GET request to /wp-admin/tools.php?page=shortcode_page
    • > User notice in wp-includes/functions.php+5905
    Function wp_enqueue_style was called incorrectly. Scripts and styles should not be registered or enqueued until the wp_enqueue_scripts, admin_enqueue_scripts, or login_enqueue_scripts hooks. This notice was triggered by the ishortcode handle. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)

SRP 50% 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
The following issues need your attention
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_enqueue_style() in wp-content/plugins/ishortcode/ishortcode.php:13

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
1 plugin tags: sortcode

ishortcode/ishortcode.php 92% from 13 tests

This is the main PHP file of "WP短代码 ishortcode" version 3..., 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:
  • Version: Use periods and digits only for your plugin's version number (ex. "1.0.3" instead of "3...")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Good job! No executable or dangerous file extensions detected259 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP14212171
CSS12288

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.27
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%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
17 PNG files occupy 0.16MB with 0.10MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
shortcode/down.png3.19KB2.32KB▼ 27.35%
shortcode/but-link.png4.95KB1.75KB▼ 64.71%
shortcode/link.png51.67KB2.30KB▼ 95.55%
shortcode/question.png3.08KB2.29KB▼ 25.55%
shortcode/warn.png52.24KB2.10KB▼ 95.97%