10% quizleads

Code Review | Quiz Leads

WordPress plugin Quiz Leads scored 10% from 54 tests.

About plugin

  • Plugin page: quizleads
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.9.0-4.7.4
  • WordPress version: 6.3.1
  • First release: May 4, 2017
  • Latest release: May 4, 2017
  • Number of updates: 15
  • Update frequency: N/A
  • Top authors: Bhuvnesh (100%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active / 1,030 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Please fix the following installer errors
  • Install procedure validation failed for this plugin
    • > User deprecated in wp-includes/functions.php+5453
    Function get_page_by_title is deprecated since version 6.2.0! Use WP_Query instead.

Server metrics [RAM: ▲0.20MB] [CPU: ▲2.31ms] Passed 4 tests

Analyzing server-side resources used by Quiz Leads
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.66 ▲0.2049.73 ▲7.61
Dashboard /wp-admin3.50 ▲0.2053.18 ▲0.30
Posts /wp-admin/edit.php3.60 ▲0.2455.07 ▲3.56
Add New Post /wp-admin/post-new.php6.09 ▲0.2097.51 ▼2.25
Media Library /wp-admin/upload.php3.43 ▲0.2047.06 ▲14.64
Add New /wp-admin/post-new.php?post_type=quizleads3.5450.42
Quiz Lead Optins /wp-admin/edit.php?post_type=quizleads3.5154.44

Server storage [IO: ▲0.33MB] [DB: ▲0.02MB] Passed 3 tests

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 17 new files
Database: 1 new table, 6 new options
New tables
wp_quizleads_tbl
New WordPress options
db_upgraded
widget_recent-posts
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-comments
can_compress_scripts

Browser metrics Passed 4 tests

An overview of browser requirements for Quiz Leads
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,929 ▲19413.65 ▼0.749.61 ▲7.8954.83 ▲11.16
Dashboard /wp-admin2,230 ▲425.90 ▲1.0299.45 ▼22.0483.70 ▲38.29
Posts /wp-admin/edit.php2,134 ▲451.99 ▼0.0338.83 ▲3.9436.51 ▲4.40
Add New Post /wp-admin/post-new.php1,563 ▲1623.11 ▲4.93707.92 ▲118.7764.28 ▲12.56
Media Library /wp-admin/upload.php1,424 ▲334.13 ▼0.13110.58 ▲17.0279.34 ▲36.84
Add New /wp-admin/post-new.php?post_type=quizleads2,9407.73179.42157.65
Quiz Lead Optins /wp-admin/edit.php?post_type=quizleads1,6512.0233.9332.16

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
Please fix the following items
  • Zombie tables detected upon uninstall: 1 table
    • wp_quizleads_tbl
  • The uninstall procedure has failed, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_theysaidso_widget
    • db_upgraded
    • can_compress_scripts
    • widget_recent-posts

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
These errors were triggered by the plugin
    • > GET request to /wp-admin/post-new.php?post_type=quizleads
    • > Warning in wp-content/plugins/quizleads/admin_settings.php+281
    in_array() expects parameter 2 to be array, null given

SRP 50% 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 take a closer look at the following
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_head() in wp-content/plugins/quizleads/templates/1/index.php:16

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser issues were found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 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
Attributes that require attention:
  • Tags: Please reduce the number of tags, currently 19 tag instead of maximum 10
  • Screenshots: Screenshot #5 (Form to generate Lead) image required
The official readme.txt is a good inspiration

quizleads/init.php 92% from 13 tests

"Quiz Leads" version 1.0's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
Please take the time to fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("quizleads.php" instead of "init.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
There were no executable files found in this plugin1,687 lines of code in 10 files:
LanguageFilesBlank linesComment linesLines of code
PHP429443985
CSS51410656
JavaScript10046

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.61
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%
Functions13
▷ Named functions13100.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
4 compressed PNG files occupy 0.03MB
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
templates/1/img/theme01-background.png28.59KB31.41KB0.00%
images/logo1.png0.65KB0.68KB0.00%
images/template.png1.65KB1.43KB▼ 13.40%
images/logo.png0.77KB0.77KB0.13%