10% ads-ez

Code Review | Ads EZ

WordPress plugin Ads EZ scored 10% from 54 tests.

About plugin

  • Plugin page: ads-ez
  • Plugin version: 3.20
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.8
  • WordPress version: 5.9.2
  • First release: Mar 6, 2015
  • Latest release: Jul 31, 2017
  • Number of updates: 108
  • Update frequency: every 8.1 days
  • Top authors: manojtd (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

10+ active / 5,264 total downloads

Benchmarks

Plugin footprint 58% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The following installer errors require your attention
  • This plugin did not install gracefully
    • > Deprecated in wp-content/plugins/ads-ez/DbHelper.php+228
    Function get_magic_quotes_gpc() is deprecated

Server metrics [RAM: ▼0.00MB] [CPU: ▼300.11ms] Passed 4 tests

Analyzing server-side resources used by Ads EZ
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.60 ▲0.0958.83 ▼39.65
Dashboard /wp-admin3.44 ▲0.0333.26 ▼0.19
Posts /wp-admin/edit.php3.66 ▲0.0239.89 ▲0.76
Add New Post /wp-admin/post-new.php6.90 ▼0.0798.80 ▼1,159.00
Media Library /wp-admin/upload.php3.31 ▲0.0227.56 ▼1.58

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 131 new files
Database: 3 new tables, 1 new option
New tables
wp_ads_administrator
wp_ads_categories
wp_ads_options_meta
New WordPress options
adsEz

Browser metrics Passed 4 tests

Ads EZ: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,791 ▲3715.82 ▲0.505.77 ▼0.412.03 ▼0.72
Dashboard /wp-admin2,897 ▲466.06 ▼0.11159.60 ▲5.84164.22 ▲2.89
Posts /wp-admin/edit.php2,690 ▼13.24 ▲0.0163.26 ▼1.10193.99 ▲39.30
Add New Post /wp-admin/post-new.php1,619 ▼1617.69 ▼1.83364.13 ▼78.41144.63 ▼15.32
Media Library /wp-admin/upload.php1,700 ▲55.56 ▲0.04136.70 ▼19.87189.50 ▼29.33
Ads EZ Lite /wp-admin/ads-ez.php260.940.0323.61

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • The plugin did not uninstall successfully, leaving 3 tables in the database
    • wp_ads_administrator
    • wp_ads_categories
    • wp_ads_options_meta

Smoke tests 25% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following
  • 40× GET requests to PHP files return non-empty strings (only 10 are shown):
    • > /wp-content/plugins/ads-ez/admin/lock.php
    • > /wp-content/plugins/ads-ez/admin/ajax/categories.php
    • > /wp-content/plugins/ads-ez/admin/login.php
    • > /wp-content/plugins/ads-ez/admin/pub.php
    • > /wp-content/plugins/ads-ez/admin/banners-new.php
    • > /wp-content/plugins/ads-ez/admin/advanced.php
    • > /wp-content/plugins/ads-ez/admin/openx.php
    • > /wp-content/plugins/ads-ez/ad.php
    • > /wp-content/plugins/ads-ez/avw.php
    • > /wp-content/plugins/ads-ez/admin/promo.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 renderFooter() in wp-content/plugins/ads-ez/admin/footer.php:4
    • > PHP Notice
      Undefined variable: badgeTarget in wp-content/plugins/ads-ez/fallback.php on line 12
    • > PHP Notice
      Undefined variable: badgeEnabled in wp-content/plugins/ads-ez/fallback.php on line 14
    • > PHP Fatal error
      Uncaught Error: Class 'EZ' not found in wp-content/plugins/ads-ez/admin/support.php:3
    • > PHP Notice
      Undefined variable: height in wp-content/plugins/ads-ez/fallback.php on line 12
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/ads-ez/EzPlugin.php:386
    • > PHP Notice
      Undefined variable: small in wp-content/plugins/ads-ez/fallback.php on line 12
    • > PHP Fatal error
      Uncaught Error: Call to undefined function menuShown() in wp-content/plugins/ads-ez/admin/intro.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/ads-ez/EzPlugin.php:386
    • > PHP Fatal error
      Uncaught Error: Class 'EZ' not found in wp-content/plugins/ads-ez/admin/tour.php:4

User-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There are user-side issues you should fix
    • > GET request to /wp-admin/ads-ez.php
    • > Network (severe)
    wp-admin/ads-ez.php - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
Attributes that require attention:
  • Screenshots: These screenshots require images: #1 (Dashboard, showing the beautifully designed admin interface.), #2 (Tour and Help, to quickly get started with Ads EZ.), #3 (Admin interface elements.), #4 (Listing your banners.), #5 (Generating invocation codes.), #6 (Configuration optons, showing help.), #7 (Editing categories.), #8 (Admin page tour sample screen, showing a dark theme.), #9 (Ad serving statistics and charts in the Pro version.), #10 (Advanced tools and Cache management in the Pro version.), #11 (OpenX/Revive replacement tools in the Pro version.), #12 (Drag-and-drop banners upload in the Pro version.)
You can look at the official readme.txt

ads-ez/ads-ez.php 92% from 13 tests

The primary PHP file in "Ads EZ" version 3.20 is used by WordPress to initiate all plugin functionality
It is important to fix the following:
  • Description: Please don't use more than 140 characters for the plugin description (currently 210 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
No dangerous file extensions were detected10,748 lines of code in 88 files:
LanguageFilesBlank linesComment linesLines of code
PHP635451856,888
CSS112161031,867
JavaScript1199951,189
SVG200749
SQL16055

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity46.71
▷ Minimum class complexity1.00
▷ Maximum class complexity157.00
Average method complexity3.88
▷ Minimum method complexity1.00
▷ Maximum method complexity30.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes14
▷ Abstract classes17.14%
▷ Concrete classes1392.86%
▷ Final classes00.00%
Methods225
▷ Static methods9341.33%
▷ Public methods21997.33%
▷ Protected methods00.00%
▷ Private methods62.67%
Functions41
▷ Named functions41100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants150.00%
▷ Class constants150.00%
▷ Public constants1100.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
26 compressed PNG files occupy 0.82MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-4.png54.08KB56.98KB0.00%
admin/img/clear.png0.50KB0.38KB▼ 22.59%
screenshot-7.png34.30KB35.96KB0.00%
admin/img/star-on.png0.62KB0.61KB▼ 1.58%
admin/img/star-off.png0.67KB0.61KB▼ 9.05%