68% fep-contact-form

Code Review | FEP Contact Form

WordPress plugin FEP Contact Form scored68%from 54 tests.

About plugin

  • Plugin page: fep-contact-form
  • Plugin version: 3.2
  • PHP version: 7.4.16
  • WordPress compatibility: 2.8-4.2
  • WordPress version: 6.3.1
  • First release: Apr 23, 2015
  • Latest release: Apr 23, 2015
  • Number of updates: 5
  • Update frequency: every 7.8 days
  • Top authors: shamim51 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,541 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
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.27MB] [CPU: ▼3.74ms] Passed 4 tests

A check of server-side resources used by FEP Contact Form
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.84 ▲0.3842.46 ▼10.35
Dashboard /wp-admin3.55 ▲0.2551.11 ▲0.88
Posts /wp-admin/edit.php3.67 ▲0.3156.00 ▲4.90
Add New Post /wp-admin/post-new.php6.16 ▲0.2792.49 ▼9.07
Media Library /wp-admin/upload.php3.48 ▲0.2543.21 ▲3.59
Instruction /wp-admin/admin.php?page=fepcf-instruction3.4436.94
Settings /wp-admin/admin.php?page=fepcf-admin-settings3.4536.73
Department Settings /wp-admin/admin.php?page=fepcf-department-settings3.4435.54

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

Analyzing filesystem and database footprints of this plugin
This plugin installed successfully
Filesystem: 15 new files
Database: 2 new tables, 9 new options
New tables
wp_fep_messages
wp_fep_meta
New WordPress options
widget_recent-comments
fep_db_version
db_upgraded
widget_recent-posts
widget_theysaidso_widget
theysaidso_admin_options
can_compress_scripts
fep_meta_db_version
FEPCF_admin_options

Browser metrics Passed 4 tests

This is an overview of browser requirements for FEP Contact Form
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,821 ▲6014.22 ▼0.341.56 ▲0.0141.66 ▲2.38
Dashboard /wp-admin2,216 ▲365.55 ▼0.0785.52 ▼7.2565.67 ▲22.90
Posts /wp-admin/edit.php2,133 ▲361.97 ▼0.0141.78 ▲5.6737.69 ▼2.39
Add New Post /wp-admin/post-new.php1,705 ▲17921.90 ▼1.92691.45 ▲37.1357.18 ▲2.03
Media Library /wp-admin/upload.php1,424 ▲274.30 ▲0.09102.99 ▼3.8080.81 ▲34.99
Instruction /wp-admin/admin.php?page=fepcf-instruction8702.0025.0324.30
Settings /wp-admin/admin.php?page=fepcf-admin-settings1,1242.1925.3435.87
Department Settings /wp-admin/admin.php?page=fepcf-department-settings8992.0123.5425.87

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% 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
  • This plugin does not fully uninstall, leaving 2 tables in the database
    • wp_fep_messages
    • wp_fep_meta
  • This plugin did not uninstall successfully, leaving 9 options in the database
    • fep_db_version
    • widget_recent-comments
    • fep_meta_db_version
    • theysaidso_admin_options
    • can_compress_scripts
    • FEPCF_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
The following issues need your attention
  • 9× 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/fep-contact-form/fepcf-menu-class.php:55
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/fep-contact-form/admin/fepcf-admin-class.php:282
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/fep-contact-form/fepcf-send-email-class.php:191
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/fep-contact-form/front-end-pm/fepcf-if-fep.php:258
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/fep-contact-form/fepcf-attachment-class.php:231
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/fep-contact-form/fepcf-main-class.php:436
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/fep-contact-form/functions.php:353
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/fep-contact-form/fep-contact-form.php:14
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/fep-contact-form/fepcf-display-class.php:467

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
There are user-side issues you should fix
    • > GET request to /wp-admin/admin.php?page=fepcf-department-settings
    • > Console-api (warning) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1 1:28609 "jQuery.Deferred exception: $(...).live is not a function" "TypeError: $(...).live is not a function\n at HTMLDocument.\u003Canonymous> (/wp-content/plugins/fep-contact-form/js/department.js?ver=3.1:4:22)\n at e (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1:2:26990)\n at t (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1:2:27292)" undefined
    • > GET request to /wp-admin/admin.php?page=fepcf-department-settings
    • > Javascript (severe) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1 1:28721 Uncaught TypeError: $(...).live is not a function

Optimizations

Plugin configuration 96% from 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
7 plugin tags: contact form, simple contact form, akismet, email, mail...

fep-contact-form/fep-contact-form.php 92% from 13 tests

The primary PHP file in "FEP Contact Form" version 3.2 is used by WordPress to initiate all plugin functionality
The following require your attention:
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6

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
Success! There were no dangerous files found in this plugin2,130 lines of code in 12 files:
LanguageFilesBlank linesComment linesLines of code
PHP94871101,802
CSS1279257
JavaScript29671

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.44
Average class complexity45.29
▷ Minimum class complexity9.00
▷ Maximum class complexity107.00
Average method complexity5.19
▷ Minimum method complexity1.00
▷ Maximum method complexity59.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods74
▷ Static methods79.46%
▷ Public methods74100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions22
▷ Named functions22100.00%
▷ Anonymous functions00.00%
Constants6
▷ Global constants6100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
There were not PNG files found in your plugin