71% flexmls-idx

Code Review | Flexmls® IDX Plugin

WordPress plugin Flexmls® IDX Plugin scored71%from 54 tests.

About plugin

  • Plugin page: flexmls-idx
  • Plugin version: 3.14.12
  • PHP compatiblity: 7.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.3.2
  • WordPress version: 6.3.1
  • First release: Jan 28, 2011
  • Latest release: Oct 27, 2023
  • Number of updates: 265
  • Update frequency: every 17.6 days
  • Top authors: flexmls (100%)

Code review

54 tests

User reviews

18 reviews

Install metrics

2,000+ active /84,282 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.09MB] [CPU: ▼11.91ms] Passed 4 tests

This is a short check of server-side resources used by Flexmls® IDX Plugin
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.69 ▲0.2342.07 ▲2.48
Dashboard /wp-admin3.49 ▲0.1950.62 ▲0.29
Posts /wp-admin/edit.php3.55 ▲0.1945.17 ▼5.60
Add New Post /wp-admin/post-new.php5.00 ▼0.8851.92 ▼44.82
Media Library /wp-admin/upload.php3.35 ▲0.1240.50 ▲6.15
Flexmls® IDX /wp-admin/admin.php?page=fmc_admin_intro3.3735.51
Settings /wp-admin/admin.php?page=fmc_admin_settings3.4135.65

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

Input-output and database impact of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 349 new files
Database: no new tables, 8 new options
New WordPress options
widget_recent-posts
widget_theysaidso_widget
db_upgraded
can_compress_scripts
widget_recent-comments
fmc_settings
theysaidso_admin_options
fmc_cache_version

Browser metrics Passed 4 tests

This is an overview of browser requirements for Flexmls® IDX Plugin
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,084 ▲32314.82 ▲0.5418.77 ▲17.1741.69 ▲1.31
Dashboard /wp-admin2,280 ▲1095.19 ▼0.3987.53 ▼1.1136.60 ▼2.12
Posts /wp-admin/edit.php2,194 ▲912.47 ▲0.5040.04 ▼0.2133.87 ▼1.94
Add New Post /wp-admin/post-new.php6,447 ▲4,91929.02 ▲5.88956.70 ▲280.3240.91 ▼13.01
Media Library /wp-admin/upload.php1,494 ▲974.68 ▲0.49102.64 ▼2.1649.05 ▲0.43
Flexmls® IDX /wp-admin/admin.php?page=fmc_admin_intro9852.4733.8437.88
Settings /wp-admin/admin.php?page=fmc_admin_settings1,4422.5244.5141.21

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_theysaidso_widget
    • can_compress_scripts
    • db_upgraded

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These server-side errors were triggered
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=fmc_admin_settings
    • > Notice in wp-content/plugins/flexmls-idx/views/admin-settings-behavior.php+108
    Undefined index: listlink
    • > GET request to /wp-admin/admin.php?page=fmc_admin_settings
    • > Warning in wp-content/plugins/flexmls-idx/views/admin-settings-behavior.php+209
    Invalid argument supplied for foreach()

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
The following issues need your attention
  • 56× PHP files perform the task of outputting text when accessed with GET requests (only 10 are shown):
    • > /wp-content/plugins/flexmls-idx/integration/wpbakery/index.php
    • > /wp-content/plugins/flexmls-idx/flexmls_connect.php
    • > /wp-content/plugins/flexmls-idx/Admin/Enqueue.php
    • > /wp-content/plugins/flexmls-idx/Widgets/autoloader.php
    • > /wp-content/plugins/flexmls-idx/integration/wpbakery/params/dropdown_tag.php
    • > /wp-content/plugins/flexmls-idx/views/admin-settings-behavior.php
    • > /wp-content/plugins/flexmls-idx/integration/wpbakery/params/callback.php
    • > /wp-content/plugins/flexmls-idx/SparkAPI/System.php
    • > /wp-content/plugins/flexmls-idx/SparkAPI/autoloader.php
    • > /wp-content/plugins/flexmls-idx/Admin/autoloader.php
  • 120× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'fmcWidget' not found in wp-content/plugins/flexmls-idx/components/search-results.php:5
    • > PHP Notice
      Undefined variable: property_types_selected in wp-content/plugins/flexmls-idx/pages/_property_types.php on line 1
    • > PHP Notice
      Undefined variable: property_types_selected in wp-content/plugins/flexmls-idx/pages/search_widget/_property_types.php on line 1
    • > PHP Fatal error
      Uncaught Error: Class 'flexmlsConnectPageCore' not found in wp-content/plugins/flexmls-idx/pages/search-results.php:3
    • > PHP Notice
      Undefined variable: property_types_selected in wp-content/plugins/flexmls-idx/views/v2/_property_types.php on line 1
    • > PHP Notice
      Undefined variable: signup_link in wp-content/plugins/flexmls-idx/views/login.php on line 12
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/flexmls-idx/views/v2/fmcSearchResults/_listings_map.php:1
    • > PHP Fatal error
      Uncaught Error: Class 'EL_FMC_shortcode' not found in wp-content/plugins/flexmls-idx/integration/elementor/modules/fmcLocationLinks.php:2
    • > PHP Fatal error
      Uncaught Error: Class 'fmcWidget' not found in wp-content/plugins/flexmls-idx/components/my-account.php:10
    • > PHP Fatal error
      Uncaught Error: Class 'fmcWidget' not found in wp-content/plugins/flexmls-idx/components/location-links.php:5

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% 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
These attributes need to be fixed:
  • Screenshots: These screenshots have no corresponding images in /assets: #1 (Our IDX Search Widget - Width, Color and Font Options Available), #2 (Listing Summary (Search Results)), #3 (Listing Detail Page), #4 (Add graphs to your market analyses using the market stats widget.), #5 (Add widgets to pages or posts using the Gutenberg Block Editor (also compatible with Classic, Elementor and WPBakery)), #6 (IDX Search Widget Settings (Gutenberg))
You can take inspiration from this readme.txt

flexmls-idx/flexmls_connect.php 85% from 13 tests

The principal PHP file in "Flexmls® IDX Plugin" v. 3.14.12 is loaded by WordPress automatically on each request
You should first fix the following items:
  • Description: Please don't use more than 140 characters for the plugin description (currently 443 characters long)
  • Main file name: Name the main plugin file the same as the plugin slug ("flexmls-idx.php" instead of "flexmls_connect.php")

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
No dangerous file extensions were detected27,536 lines of code in 217 files:
LanguageFilesBlank linesComment linesLines of code
PHP1584,5501,70921,338
JSON1005,498
CSS132110276
JavaScript356436243
SVG502114
JSX530467

PHP code 50% from 2 tests

This is a very shot review of cyclomatic complexity and code structure
Please fix the following
  • Please reduce cyclomatic complexity of methods to less than 100 (currently 135)
Cyclomatic complexity
Average complexity per logical line of code0.37
Average class complexity22.99
▷ Minimum class complexity1.00
▷ Maximum class complexity198.00
Average method complexity3.78
▷ Minimum method complexity1.00
▷ Maximum method complexity135.00
Code structure
Namespaces4
Interfaces3
Traits0
Classes102
▷ Abstract classes00.00%
▷ Concrete classes102100.00%
▷ Final classes00.00%
Methods833
▷ Static methods19923.89%
▷ Public methods69683.55%
▷ Protected methods9711.64%
▷ Private methods404.80%
Functions35
▷ Named functions2468.57%
▷ Anonymous functions1131.43%
Constants6
▷ Global constants116.67%
▷ Class constants583.33%
▷ Public constants5100.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
80 PNG files occupy 1.81MB with 0.42MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/showing.png0.66KB0.55KB▼ 17.50%
assets/images/chosen-sprite.png0.53KB0.88KB0.00%
images/next-vertical.png3.73KB1.88KB▼ 49.46%
images/controls.png1.22KB1.27KB0.00%
assets/images/prev-horizontal.png4.22KB2.20KB▼ 47.92%