68% wp-greet

Code Review | wp-greet

WordPress plugin wp-greet scored68%from 54 tests.

About plugin

  • Plugin page: wp-greet
  • Plugin version: 6.2
  • PHP version: 7.4.16
  • WordPress compatibility: 4.1-6.1
  • WordPress version: 6.3.1
  • First release: Apr 6, 2008
  • Latest release: Mar 3, 2023
  • Number of updates: 133
  • Update frequency: every 42.1 days
  • Top authors: tuxlog (100%)

Code review

54 tests

User reviews

10 reviews

Install metrics

60+ active /33,263 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully

Server metrics [RAM: ▲0.80MB] [CPU: ▲10.12ms] Passed 4 tests

An overview of server-side resources used by wp-greet
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /4.27 ▲0.8155.89 ▲9.20
Dashboard /wp-admin4.10 ▲0.7963.25 ▲8.79
Posts /wp-admin/edit.php4.15 ▲0.7965.28 ▲8.28
Add New Post /wp-admin/post-new.php6.70 ▲0.81112.38 ▲14.22
Media Library /wp-admin/upload.php4.04 ▲0.8152.98 ▲14.71
Mail /wp-admin/admin.php?page=wp-greet/wpg-admin-mail.php3.9946.31
Security /wp-admin/admin.php?page=wp-greet/wpg-admin-sec.php3.9945.90
Galleries /wp-admin/admin.php?page=wp-greet/wpg-admin-gal.php3.9945.04
Logging /wp-admin/admin.php?page=wp-greet/wpg-admin-log.php3.9948.83
wp-greet /wp-admin/admin.php?page=wp-greet/wpg-admin.php3.9946.13

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 368 new files
Database: 2 new tables, 38 new options
New tables
wp_wpgreet_cards
wp_wpgreet_stats
New WordPress options
wp-greet-mailconfirm
db_upgraded
wp-greet-autofillform
wp-greet-tinymce
can_compress_scripts
wp-greet-ectext
widget_recent-posts
wp-greet-termsofusage
wp-greet-stampimage
wp-greet-usesmtp
...

Browser metrics Passed 4 tests

Checking browser requirements for wp-greet
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,854 ▲6814.24 ▼0.122.03 ▼0.4539.89 ▼8.02
Dashboard /wp-admin2,238 ▲585.56 ▼0.05103.22 ▲7.3187.79 ▲49.66
Posts /wp-admin/edit.php2,154 ▲542.03 ▼0.0038.50 ▼1.4136.64 ▲0.63
Add New Post /wp-admin/post-new.php1,564 ▲3823.07 ▲0.08709.76 ▲15.14148.41 ▲87.32
Media Library /wp-admin/upload.php1,448 ▲514.14 ▼0.08105.41 ▲5.1977.92 ▲33.54
Mail /wp-admin/admin.php?page=wp-greet/wpg-admin-mail.php1,0632.0524.7630.64
Security /wp-admin/admin.php?page=wp-greet/wpg-admin-sec.php1,1042.1823.9227.58
Galleries /wp-admin/admin.php?page=wp-greet/wpg-admin-gal.php8652.2026.7228.09
Logging /wp-admin/admin.php?page=wp-greet/wpg-admin-log.php8852.0227.4133.26
wp-greet /wp-admin/admin.php?page=wp-greet/wpg-admin.php1,3012.0325.7231.73

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • This plugin does not fully uninstall, leaving 2 tables in the database
    • wp_wpgreet_cards
    • wp_wpgreet_stats
  • Zombie WordPress options detected upon uninstall: 38 options
    • wp-greet-usesmtp
    • wp-greet-linesperpage
    • can_compress_scripts
    • wp-greet-carddays
    • wp-greet-fields
    • wp-greet-termsofusage
    • wp-greet-onlinecard
    • wp-greet-captcha
    • wp-greet-smtp-port
    • db_upgraded
    • ...

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though no errors were found, this is by no means an exhaustive test

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
Almost there! Just fix the following items
  • 11× PHP files perform the task of outputting text when accessed with GET requests (only 10 are shown):
    • > /wp-content/plugins/wp-greet/wpg-admin.php
    • > /wp-content/plugins/wp-greet/wpg-admin-gal.php
    • > /wp-content/plugins/wp-greet/wpg-func-mail6.php
    • > /wp-content/plugins/wp-greet/wpg-admin-mail.php
    • > /wp-content/plugins/wp-greet/wpg-func.php
    • > /wp-content/plugins/wp-greet/setup.php
    • > /wp-content/plugins/wp-greet/wpg-admin-reschedule.php
    • > /wp-content/plugins/wp-greet/wp-greet.php
    • > /wp-content/plugins/wp-greet/wpg-admin-log.php
    • > /wp-content/plugins/wp-greet/wpg-func-mail.php
  • 39× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Warning
      imagescale() expects parameter 1 to be resource, bool given in wp-content/plugins/wp-greet/wpg-stamped.php on line 83
    • > PHP Warning
      imagesy() expects parameter 1 to be resource, null given in wp-content/plugins/wp-greet/wpg-stamped.php on line 85
    • > PHP Notice
      Undefined index: sti in wp-content/plugins/wp-greet/wpg-stamped.php on line 25
    • > PHP Warning
      file_get_contents(): Filename cannot be empty in wp-content/plugins/wp-greet/wpg-stamped.php on line 43
    • > PHP Warning
      imagedestroy() expects parameter 1 to be resource, bool given in wp-content/plugins/wp-greet/wpg-stamped.php on line 107
    • > PHP Warning
      file_get_contents(): Filename cannot be empty in wp-content/plugins/wp-greet/wpg-stamped.php on line 42
    • > PHP Notice
      Undefined variable: s in wp-content/plugins/wp-greet/wpg-stamped.php on line 70
    • > PHP Warning
      include_once(ABSPATHwp-admin/includes/plugin.php): failed to open stream: No such file or directory in wp-content/plugins/wp-greet/templates/wp-greet-form-template.php on line 53
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/wp-greet/wpg-offerstamp.php:139
    • > PHP Warning
      imagedestroy() expects parameter 1 to be resource, null given in wp-content/plugins/wp-greet/wpg-stamped.php on line 109

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 Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
5 plugin tags: email, send, plugin, greetcard, greetingcard

wp-greet/wp-greet.php Passed 13 tests

"wp-greet" version 6.2's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
79 characters long description:
wp-greet is a WordPress plugin to send greeting cards from your WordPress blog.

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
There were no executable files found in this plugin44,446 lines of code in 295 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript1628711,01320,228
PO File193,1023,9757,476
CSS14282357,279
TypeScript81504,897
PHP191,0271,2144,566

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.36
Average class complexity16.00
▷ Minimum class complexity16.00
▷ Maximum class complexity16.00
Average method complexity3.50
▷ Minimum method complexity2.00
▷ Maximum method complexity11.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods12
▷ Static methods00.00%
▷ Public methods12100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions66
▷ Named functions66100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
15 PNG files occupy 0.14MB with 0.05MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
stamps/TuxStamp3.png7.30KB6.22KB▼ 14.81%
stamps/TuxStamp4.png7.38KB4.91KB▼ 33.51%
tuxstamp4.png7.38KB4.91KB▼ 33.51%
tuxstamp1.png14.68KB8.57KB▼ 41.59%
stamps/TuxStamp1.png14.68KB8.57KB▼ 41.59%