66% webengage

Code Review | WebEngage Feedback, Survey and Notification

WordPress plugin WebEngage Feedback, Survey and Notification scored66%from 54 tests.

About plugin

  • Plugin page: webengage
  • Plugin version: 2.0.4
  • PHP version: 7.4.16
  • WordPress compatibility: 2.7-4.3.1
  • WordPress version: 6.3.1
  • First release: Feb 3, 2012
  • Latest release: Jul 12, 2016
  • Number of updates: 123
  • Update frequency: every 13.2 days
  • Top authors: avlesh (100%)

Code review

54 tests

User reviews

17 reviews

Install metrics

100+ active /30,230 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Install script ran successfully

Server metrics [RAM: ▲0.03MB] [CPU: ▼2.27ms] Passed 4 tests

An overview of server-side resources used by WebEngage Feedback, Survey and Notification
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0340.61 ▼3.81
Dashboard /wp-admin3.33 ▲0.0349.76 ▼0.35
Posts /wp-admin/edit.php3.38 ▲0.0352.18 ▼2.79
Add New Post /wp-admin/post-new.php5.91 ▲0.03100.97 ▼2.12
Media Library /wp-admin/upload.php3.26 ▲0.0340.49 ▲0.23
WebEngage /wp-admin/options-general.php?page=webengage3.2032.92

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

Analyzing filesystem and database footprints of this plugin
This plugin installed successfully
Filesystem: 27 new files
Database: no new tables, 7 new options
New WordPress options
can_compress_scripts
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-posts
db_upgraded
webengage_redirect_on_first_activation
widget_recent-comments

Browser metrics Passed 4 tests

This is an overview of browser requirements for WebEngage Feedback, Survey and Notification
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲3313.30 ▼0.881.91 ▼0.0143.13 ▲2.26
Dashboard /wp-admin2,213 ▲254.89 ▼0.03114.55 ▲7.3444.27 ▲0.43
Posts /wp-admin/edit.php2,093 ▲12.03 ▼0.0235.63 ▼5.3036.12 ▼3.59
Add New Post /wp-admin/post-new.php1,536 ▲823.38 ▲5.13675.77 ▲57.9059.22 ▼0.86
Media Library /wp-admin/upload.php1,389 ▲14.24 ▲0.0797.79 ▼5.9441.44 ▼4.22
WebEngage /wp-admin/options-general.php?page=webengage8481.8628.3328.93

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • db_upgraded
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments
    • widget_theysaidso_widget
    • theysaidso_admin_options

Smoke tests 0% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Smoke test failed, please fix the following
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=webengage
    • > Notice in wp-content/plugins/webengage/options.php+19
    Undefined index: weAction
    • > GET request to /wp-admin/options-general.php?page=webengage
    • > Notice in wp-content/plugins/webengage/renderer.php+28
    Undefined index: message
    • > GET request to /wp-admin/options-general.php?page=webengage
    • > Notice in wp-content/plugins/webengage/renderer.php+33
    Undefined index: error-message

SRP 0% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please fix the following items
  • 2× PHP files output text when accessed directly:
    • > /wp-content/plugins/webengage/callback.php
    • > /wp-content/plugins/webengage/resize.php
  • 3× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/webengage/renderer.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/webengage/webengage.php:27
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/webengage/options.php:3

User-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
These are user-side errors you should fix
    • > GET request to /wp-admin/options-general.php?page=webengage
    • > Other (severe) in unknown
    chrome-error://chromewebdata/ - Refused to display 'https://webengage.com/' in a frame because it set 'X-Frame-Options' to 'sameorigin'.

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
These attributes need to be fixed:
  • Screenshots: Add images for these screenshots: #1 (Feedback tab in action on a customer's website.), #2 (Short survey in action on a customer's website.), #3 (Fancy callout notification in action), #4 (Feedback inbox), #5 (Feedback thread submitted by a user.), #6 (Creating a notification using dashboard), #7 (Survey response overview screenshot), #8 (Creating a survey using dashboard)
  • Tags: Please delete some tags, you are using 24 tag instead of maximum 10
You can look at the official readme.txt

webengage/webengage.php 92% from 13 tests

The main PHP file in "WebEngage Feedback, Survey and Notification" ver. 2.0.4 adds more information about the plugin and also serves as the entry point for this plugin
You should first fix the following items:
  • Description: The description should be shorter than 140 characters (currently 676 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Everything looks great! No dangerous files found in this plugin434 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP5730316
CSS1221118

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.31
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%
Constants3
▷ Global constants3100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
11 PNG files occupy 1.24MB with 0.41MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-6.png210.31KB107.13KB▼ 49.06%
logo.png1.68KB1.57KB▼ 6.22%
screenshot-5.png194.76KB88.81KB▼ 54.40%
external.png0.16KB0.16KB0.00%
screenshot-7.png150.42KB68.17KB▼ 54.68%