73% top-page-quality-analytics

Code Review | TOP Page Quality Analytics

WordPress plugin TOP Page Quality Analytics scored 73% from 54 tests.

About plugin

  • Plugin page: top-page-quality-...
  • Plugin version: 2.8.6
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5.1-3.7.1
  • WordPress version: 5.9.2
  • First release: Oct 30, 2013
  • Latest release: Dec 2, 2013
  • Number of updates: 7
  • Update frequency: every 4.7 days
  • Top authors: janhvizdak (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 1,253 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
The plugin installed gracefully, with no errors

Server metrics [RAM: ▼2.40MB] [CPU: ▼340.83ms] Passed 4 tests

A check of server-side resources used by TOP Page Quality Analytics
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /1.97 ▼1.544.32 ▼47.09
Dashboard /wp-admin1.99 ▼1.424.09 ▼28.88
Posts /wp-admin/edit.php1.99 ▼1.653.78 ▼33.56
Add New Post /wp-admin/post-new.php1.99 ▼4.984.55 ▼1,253.80
Media Library /wp-admin/upload.php1.99 ▼1.304.11 ▼18.55
TOP Page Quality Analytics /wp-admin/tools.php?page=top-analytics1.994.53

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 8 new files
Database: 1 new table, no new options
New tables
wp_tracking_app

Browser metrics Passed 4 tests

An overview of browser requirements for TOP Page Quality Analytics
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,896 ▲14116.53 ▲0.859.07 ▲2.0621.42 ▲18.52
Dashboard /wp-admin2,897 ▲396.15 ▼0.14118.53 ▼16.84154.53 ▼6.02
Posts /wp-admin/edit.php2,697 ▲33.22 ▼0.0163.18 ▼0.86140.77 ▼2.04
Add New Post /wp-admin/post-new.php1,767 ▲10617.18 ▲1.02407.87 ▲7.73155.69 ▲3.89
Media Library /wp-admin/upload.php1,708 ▲135.53 ▼0.01149.74 ▲15.83186.36 ▼0.06
TOP Page Quality Analytics /wp-admin/tools.php?page=top-analytics1,1172.5454.67147.26

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
  • Uninstall procedure had uncaught errors
    • > Deprecated in wp-includes/class-wp-hook.php+307
    Non-static method top_analytics::analytics_init() should not be called statically
  • Zombie tables detected upon uninstall: 1 table
    • wp_tracking_app

Smoke tests 75% 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/tools.php?page=top-analytics
    • > Deprecated in wp-includes/class-wp-hook.php+307
    Non-static method top_analytics::analytics_init() should not be called statically
    • > GET request to /wp-admin/tools.php?page=top-analytics
    • > Deprecated in wp-includes/class-wp-hook.php+307
    Non-static method top_analytics::styles() should not be called statically
    • > GET request to /wp-admin/tools.php?page=top-analytics
    • > Deprecated in wp-includes/class-wp-hook.php+307
    Non-static method top_analytics::javascript() should not be called statically
    • > GET request to /wp-admin/tools.php?page=top-analytics
    • > Deprecated in wp-includes/class-wp-hook.php+307
    Non-static method top_analytics::add_mgmt_page() should not be called statically
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/tools.php?page=top-analytics
    • > User deprecated in wp-includes/functions.php+5600
    has_cap was called with an argument that is deprecated since version 2.0.0! Usage of user levels is deprecated. Use capabilities instead.
    • > GET request to /wp-admin/tools.php?page=top-analytics
    • > Deprecated in wp-includes/class-wp-hook.php+307
    Non-static method top_analytics::main_screen() should not be called statically
    • > GET request to /wp-admin/tools.php?page=top-analytics
    • > Notice in wp-content/plugins/top-page-quality-analytics/top-analytics.php+150
    Undefined index: identifier_top

SRP Passed 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
No output text or server-side errors detected on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 86% from 29 tests

readme.txt 94% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
These attributes need your attention:
  • Plugin Name: "Plugin Name" should be replaced with the name of your plugin on the first line ( === top-page-quality-analytics === )
Please take inspiration from this readme.txt

top-page-quality-analytics/top-analytics.php 77% from 13 tests

The principal PHP file in "TOP Page Quality Analytics" v. 2.8.6 is loaded by WordPress automatically on each request
The following require your attention:
  • Description: Please don't use more than 140 characters for the plugin description (currently 178 characters long)
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6
  • Main file name: The principal plugin file should be the same as the plugin slug ("top-page-quality-analytics.php" instead of "top-analytics.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Everything looks great! No dangerous files found in this plugin706 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PO File28490402
PHP113232236
CSS110959
JavaScript1219

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.09
Average class complexity13.00
▷ Minimum class complexity13.00
▷ Maximum class complexity13.00
Average method complexity2.09
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods11
▷ Static methods00.00%
▷ Public methods11100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants8
▷ Global constants00.00%
▷ Class constants8100.00%
▷ Public constants8100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
No PNG files were detected