84% wpik-wordpress-basic-ajax-form

Code Review | Wpik WordPress Basic Ajax Form

WordPress plugin Wpik WordPress Basic Ajax Form scored 84% from 54 tests.

About plugin

  • Plugin page: wpik-wordpress-ba...
  • Plugin version: 1.0
  • PHP compatiblity: 7.3+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.6.1
  • WordPress version: 5.8.1
  • First release: Oct 13, 2018
  • Latest release: Feb 16, 2021
  • Number of updates: 5
  • Update frequency: every 171.6 days
  • Top authors: awanhrp (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 294 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▼1.85MB] [CPU: ▼189.17ms] Passed 4 tests

This is a short check of server-side resources used by Wpik WordPress Basic Ajax Form
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /1.78 ▼0.945.14 ▼23.39
Dashboard /wp-admin1.80 ▼1.265.71 ▼42.91
Posts /wp-admin/edit.php1.80 ▼1.315.62 ▼39.80
Add New Post /wp-admin/post-new.php1.80 ▼3.645.43 ▼645.80
Media Library /wp-admin/upload.php1.80 ▼1.214.90 ▼28.15

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

Filesystem and database footprint
There were no storage issued detected upon installing this plugin
Filesystem: 3 new files
Database: 1 new table, no new options
New tables
wp_ajax_demo

Browser metrics Passed 4 tests

Checking browser requirements for Wpik WordPress Basic Ajax Form
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,842 ▲24616.42 ▲0.4715.05 ▲0.4950.95 ▲3.91
Dashboard /wp-admin2,975 ▲446.10 ▲0.15147.46 ▼10.14108.72 ▼3.03
Posts /wp-admin/edit.php2,744 ▲52.73 ▲0.0165.27 ▼3.5285.05 ▼4.32
Add New Post /wp-admin/post-new.php1,651 ▼2121.43 ▲2.54290.35 ▼107.80121.54 ▲18.25
Media Library /wp-admin/upload.php1,812 ▲55.03 ▲0.02150.38 ▼3.12110.55 ▼0.05

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
These items require your attention
  • Uninstall procedure validation failed for this plugin
    • > User notice in wp-includes/functions.php+5663
    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 imran1 handle. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)

Smoke tests 75% 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 50% from 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
The following issues need your attention
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/wpik-wordpress-basic-ajax-form/index.php:61

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
These attributes need to be fixed:
  • Screenshots: Screenshot #1 (Wpik WordPress Basic Ajax Form) image missing
The official readme.txt might help

wpik-wordpress-basic-ajax-form/index.php 92% from 13 tests

The main file in "Wpik WordPress Basic Ajax Form" v. 1.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
It is important to fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("wpik-wordpress-basic-ajax-form.php" instead of "index.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Success! There were no dangerous files found in this plugin89 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP1374875
JavaScript111114

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.07
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%
Functions5
▷ Named functions5100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG files were detected