68% insertify

Code Review | Insertify - Ad,HTML,CSS,JS,PHP,PDF,Header & Footer

WordPress plugin Insertify - Ad,HTML,CSS,JS,PHP,PDF,Header & Footer scored68%from 54 tests.

About plugin

  • Plugin page: insertify
  • Plugin version: 1.1.4
  • PHP version: 7.4.16
  • WordPress compatibility: 3.8-5.0.2
  • WordPress version: 6.3.1
  • First release: Jul 27, 2018
  • Latest release: Dec 29, 2018
  • Number of updates: 37
  • Update frequency: every 4.2 days
  • Top authors: sourov (100%)

Code review

54 tests

User reviews

5 reviews

Install metrics

50+ active /2,198 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: ▲0.15MB] [CPU: ▲0.57ms] Passed 4 tests

An overview of server-side resources used by Insertify - Ad,HTML,CSS,JS,PHP,PDF,Header & Footer
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.60 ▲0.1343.79 ▲5.45
Dashboard /wp-admin3.45 ▲0.1451.94 ▲1.13
Posts /wp-admin/edit.php3.56 ▲0.2153.93 ▲2.94
Add New Post /wp-admin/post-new.php6.05 ▲0.1687.62 ▼3.07
Media Library /wp-admin/upload.php3.37 ▲0.1436.27 ▲1.28
Insertify /wp-admin/admin.php?page=icps-main3.3432.07
Site Info /wp-admin/admin.php?page=icps_site_info3.3632.52
Add New /wp-admin/admin.php?page=icps_add_new3.4742.56
Entries /wp-admin/admin.php?page=icps_entries3.3633.96

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

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 37 new files
Database: 1 new table, 6 new options
New tables
wp_insertify
New WordPress options
widget_recent-comments
widget_theysaidso_widget
widget_recent-posts
can_compress_scripts
theysaidso_admin_options
db_upgraded

Browser metrics Passed 4 tests

An overview of browser requirements for Insertify - Ad,HTML,CSS,JS,PHP,PDF,Header & Footer
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,827 ▲6614.66 ▲0.501.64 ▲0.0344.29 ▲3.07
Dashboard /wp-admin2,214 ▲435.61 ▲0.0892.55 ▲5.7582.87 ▲39.36
Posts /wp-admin/edit.php2,137 ▲372.01 ▲0.0136.62 ▲0.4334.96 ▲0.11
Add New Post /wp-admin/post-new.php1,556 ▲2123.01 ▼0.37752.95 ▲113.8867.47 ▲11.85
Media Library /wp-admin/upload.php1,431 ▲344.23 ▼0.0899.24 ▼0.3474.13 ▲31.56
Insertify /wp-admin/admin.php?page=icps-main1,1021.7023.4642.75
Site Info /wp-admin/admin.php?page=icps_site_info1,0591.6425.5477.20
Add New /wp-admin/admin.php?page=icps_add_new2,90110.61217.8782.63
Entries /wp-admin/admin.php?page=icps_entries8241.6924.4535.66

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
  • Zombie tables were found after uninstall: 1 table
    • wp_insertify
  • This plugin does not fully uninstall, leaving 6 options in the database
    • theysaidso_admin_options
    • db_upgraded
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

SRP 0% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please take a closer look at the following
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/insertify/dashboard/functions.php
  • 15× 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 plugin_dir_path() in wp-content/plugins/insertify/regular.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/insertify/apply/content_in_post.php:124
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/insertify/shortcodes.php:178
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/insertify/regular/comments.php:126
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/insertify/regular/page-post.php:147
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/insertify/regular/user.php:87
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/insertify/apply/js_in_admin.php:39
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/insertify/apply/embed_in_site.php:36
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/insertify/apply/css_in_site.php:39
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/insertify/dashboard.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
Please fix the following attributes:
  • Tags: There are too many tags (18 tag instead of maximum 10)
The official readme.txt is a good inspiration

insertify/insertify.php 92% from 13 tests

The entry point to "Insertify - Ad,HTML,CSS,JS,PHP,PDF,Header & Footer" version 1.1.4 is a PHP file that has certain tags in its header comment area
Please make the necessary changes and fix the following:
  • Description: Please don't use more than 140 characters for the plugin description (currently 214 characters long)

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
Everything looks great! No dangerous files found in this plugin2,294 lines of code in 35 files:
LanguageFilesBlank linesComment linesLines of code
PHP291,3032692,151
CSS3341130
JavaScript3111113

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.25
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%
Functions40
▷ Named functions40100.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
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
image/ic-logo.png2.46KB1.33KB▼ 46.11%