84% placehold-gravity-forms

Code Review | Placehold (Gravity Forms)

WordPress plugin Placehold (Gravity Forms) scored 84% from 54 tests.

About plugin

  • Plugin page: placehold-gravity...
  • Plugin version: 1.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.0
  • WordPress version: 6.3.1
  • First release: Jun 25, 2014
  • Latest release: Oct 2, 2014
  • Number of updates: 17
  • Update frequency: every 5.8 days
  • Top authors: 51seven (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

100+ active / 1,708 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
This plugin's installer ran successfully

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

Analyzing server-side resources used by Placehold (Gravity Forms)
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0144.78 ▲4.84
Dashboard /wp-admin3.31 ▲0.0150.51 ▼4.94
Posts /wp-admin/edit.php3.36 ▲0.0048.68 ▲1.03
Add New Post /wp-admin/post-new.php5.89 ▲0.0194.48 ▼7.81
Media Library /wp-admin/upload.php3.23 ▲0.0037.68 ▲2.14

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Placehold (Gravity Forms)
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6513.61 ▼0.931.66 ▼0.0339.19 ▼3.97
Dashboard /wp-admin2,203 ▲125.85 ▲0.8497.49 ▼5.9240.38 ▼5.56
Posts /wp-admin/edit.php2,092 ▲32.02 ▼0.0339.90 ▲6.2534.64 ▲0.72
Add New Post /wp-admin/post-new.php1,533 ▲1423.27 ▼0.07654.43 ▲3.0458.38 ▲2.15
Media Library /wp-admin/upload.php1,385 ▼34.19 ▼0.0494.20 ▼11.3045.26 ▼2.29

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
These items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • db_upgraded
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for 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
Almost there! Just fix the following items
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/placehold-gravity-forms/placehold-gravity-forms.php:83

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 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
5 plugin tags: textarea, input, gravity forms, gravity, placeholder

placehold-gravity-forms/placehold-gravity-forms.php Passed 13 tests

The primary PHP file in "Placehold (Gravity Forms)" version 1.2 is used by WordPress to initiate all plugin functionality
43 characters long description:
Adds a placeholder to inputs Gravity Forms.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Everything looks great! No dangerous files found in this plugin40 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP183740

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.28
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%
Functions3
▷ Named functions3100.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
There are no PNG files in this plugin