78% ads-inside-post-aipwp

Code Review | ADs Inside Post

WordPress plugin ADs Inside Post scored78%from 54 tests.

About plugin

  • Plugin page: ads-inside-post-a...
  • Plugin version: 1.7
  • PHP version: 7.4.16
  • WordPress compatibility: 2.3-4.1
  • WordPress version: 6.3.1
  • First release: Nov 20, 2013
  • Latest release: Mar 20, 2015
  • Number of updates: 15
  • Update frequency: every 32.4 days
  • Top authors: rajika4ever (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /5,948 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
This plugin's installer ran successfully

Server metrics [RAM: ▼0.19MB] [CPU: ▼18.81ms] Passed 4 tests

This is a short check of server-side resources used by ADs Inside Post
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0541.75 ▲2.82
Dashboard /wp-admin3.11 ▼0.2030.76 ▼17.19
Posts /wp-admin/edit.php3.24 ▼0.1133.93 ▼20.49
Add New Post /wp-admin/post-new.php5.49 ▼0.4076.23 ▼29.01
Media Library /wp-admin/upload.php3.19 ▼0.0431.63 ▼8.56

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 6 new files
Database: 1 new table, 6 new options
New tables
wp_AIPWP_ADS
New WordPress options
widget_recent-posts
widget_recent-comments
widget_theysaidso_widget
can_compress_scripts
theysaidso_admin_options
db_upgraded

Browser metrics Passed 4 tests

Checking browser requirements for ADs Inside Post
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,812 ▲5114.35 ▲0.061.72 ▼0.3544.28 ▼0.99
Dashboard /wp-admin2,216 ▲395.59 ▲0.0684.13 ▼6.7941.05 ▼1.44
Posts /wp-admin/edit.php2,121 ▲211.97 ▲0.0236.31 ▼6.4635.65 ▼9.40
Add New Post /wp-admin/post-new.php1,547 ▲2123.03 ▼0.30651.59 ▼35.3157.42 ▼1.50
Media Library /wp-admin/upload.php1,421 ▲214.29 ▲0.07112.32 ▼7.2846.84 ▼6.42

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
You still need to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-comments
    • widget_recent-posts
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options
    • 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
Everything seems fine, however this is by no means an exhaustive test

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 fix the following items
  • 1× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/ads-inside-post-aipwp/admin/admin.php
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/ads-inside-post-aipwp/index.php:20

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% 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
Please fix the following attributes:
  • Plugin Name: You should set the name of your plugin on the first line ( === ads-inside-post-aipwp === )
  • Screenshots: These screenshots have no corresponding images in /assets: #1 (This shows ADs Inside Post in action), #2 (Shows Setting Options), #3 (Shows how to add the shortcode in posts/pages), #4 (Shows the Shortcode attrubute handling)
Please take inspiration from this readme.txt

ads-inside-post-aipwp/index.php 92% from 13 tests

The primary PHP file in "ADs Inside Post" version 1.7 is used by WordPress to initiate all plugin functionality
You should first fix the following items:
  • Main file name: Name the main plugin file the same as the plugin slug ("ads-inside-post-aipwp.php" instead of "index.php")

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
Everything looks great! No dangerous files found in this plugin582 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP48535565
CSS19017

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.18
Average class complexity1.00
▷ Minimum class complexity1.00
▷ Maximum class complexity1.00
Average method complexity1.00
▷ Minimum method complexity1.00
▷ Maximum method complexity1.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods3
▷ Static methods00.00%
▷ Public methods3100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions15
▷ Named functions15100.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
PNG images were not found in this plugin