68% ppm-faq

Code Review | PPM FAQ

WordPress plugin PPM FAQ scored68%from 54 tests.

About plugin

  • Plugin page: ppm-faq
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.3-3.5.1
  • WordPress version: 6.3.1
  • First release: May 27, 2013
  • Latest release: Jun 3, 2013
  • Number of updates: 9
  • Update frequency: every 0.8 days
  • Top authors: perfectpointmarketing (100%)

Code review

54 tests

User reviews

5 reviews

Install metrics

40+ active /2,336 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▼1.93MB] [CPU: ▼56.75ms] Passed 4 tests

A check of server-side resources used by PPM FAQ
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.06 ▼1.404.07 ▼42.42
Dashboard /wp-admin2.08 ▼1.237.34 ▼47.72
Posts /wp-admin/edit.php2.08 ▼1.285.10 ▼40.71
Add New Post /wp-admin/post-new.php2.08 ▼3.815.36 ▼96.14
Media Library /wp-admin/upload.php2.08 ▼1.157.67 ▼31.69
Add New /wp-admin/post-new.php?post_type=ppm-faq2.085.54
FAQs /wp-admin/edit.php?post_type=ppm-faq2.087.01

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

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 9 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
db_upgraded
widget_recent-comments
theysaidso_admin_options
widget_theysaidso_widget
can_compress_scripts

Browser metrics Passed 4 tests

This is an overview of browser requirements for PPM FAQ
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,921 ▲18613.99 ▼0.189.11 ▲7.1940.58 ▼8.83
Dashboard /wp-admin2,240 ▲524.87 ▼0.99126.86 ▲9.9645.13 ▼2.49
Posts /wp-admin/edit.php2,120 ▲312.05 ▲0.0450.57 ▲14.0237.78 ▲2.46
Add New Post /wp-admin/post-new.php1,541 ▲822.95 ▼0.25632.82 ▼37.6770.55 ▲12.36
Media Library /wp-admin/upload.php1,419 ▲314.30 ▲0.11133.55 ▲8.9955.28 ▲4.48
Add New /wp-admin/post-new.php?post_type=ppm-faq2,2277.63186.3570.16
FAQs /wp-admin/edit.php?post_type=ppm-faq1,0842.0035.2931.47

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
You still need to fix the following
  • Uninstall procedure validation failed for this plugin
    • > User notice in wp-includes/functions.php+5905
    Function wp_enqueue_script 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 ppm-faq-plugin-script-active 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_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments
    • theysaidso_admin_options
    • db_upgraded
    • can_compress_scripts

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Smoke test failed, please fix the following
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/edit.php?post_type=ppm-faq
    • > POST request to /wp-admin/admin-ajax.php
    • > User notice in wp-includes/functions.php+5905
    Function wp_enqueue_script 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 ppm-faq-plugin-script-active handle. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/edit.php?post_type=ppm-faq
    • > POST request to /wp-admin/admin-ajax.php
    • > 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 ppm-faq-plugin-style handle. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)
  • 19 occurences, only the last one shown
    • > GET request to /wp-admin/edit.php?post_type=ppm-faq
    • > POST request to /wp-cron.php?doing_wp_cron=1696658530.1360850334167480468750
    • > Notice in wp-content/plugins/pressforward/Core/Utility/Retrieval.php+204
    Undefined offset: 0
  • 19 occurences, only the last one shown
    • > GET request to /wp-admin/edit.php?post_type=ppm-faq
    • > POST request to /wp-cron.php?doing_wp_cron=1696658530.1360850334167480468750
    • > Notice in wp-content/plugins/pressforward/Core/Utility/Retrieval.php+205
    Trying to get property 'guid' of non-object
  • 74 occurences, only the last one shown
    • > GET request to /wp-admin/edit.php?post_type=ppm-faq
    • > POST request to /wp-cron.php?doing_wp_cron=1696658530.1360850334167480468750
    • > Notice in wp-content/plugins/pressforward/Core/Utility/Retrieval.php+206
    Trying to get property 'ID' of non-object
  • 18 occurences, only the last one shown
    • > GET request to /wp-admin/edit.php?post_type=ppm-faq
    • > POST request to /wp-cron.php?doing_wp_cron=1696658530.1360850334167480468750
    • > Notice in wp-content/plugins/pressforward/Core/Utility/Retrieval.php+222
    Trying to get property 'post_title' of non-object

SRP 50% 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
The following issues need your attention
  • 3× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/ppm-faq/faq-type.php:31
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_basename() in wp-content/plugins/ppm-faq/plugin-hook.php:13
    • > PHP Warning
      Use of undefined constant WP_PLUGIN_URL - assumed 'WP_PLUGIN_URL' (this will throw an Error in a future version of PHP) in wp-content/plugins/ppm-faq/plugin-hook.php on line 13

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% 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
Attributes that require attention:
  • Screenshots: These screenshots do not have images: #1 (PPM FAQ in a post), #2 (PPM FAQ Admin Panel Screenshot.)
  • Donate link: Please fix this invalid URI: ""
The official readme.txt might help

ppm-faq/plugin-hook.php 92% from 13 tests

This is the main PHP file of "PPM FAQ" version 1.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
You should first fix the following items:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("ppm-faq.php" instead of "plugin-hook.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Everything looks great! No dangerous files found in this plugin108 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP2191971
JavaScript262536
CSS1001

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.05
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%
Functions8
▷ Named functions8100.00%
▷ Anonymous functions00.00%
Constants8
▷ Global constants8100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and 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
js/faq.png1.32KB0.61KB▼ 54.04%