WordPress.DB.RestrictedFunctions.mysql_mysqli_free_result

mysql mysqli free result

The plugin uses a raw MySQL extension or class instead of WordPress database APIs.

medium weight

Why It Shows Up

The scan found `mysql_*`, `mysqli_*`, PDO MySQL, or related database functions in plugin code.

Why It Matters

Bypassing `$wpdb` can ignore WordPress database configuration, escaping conventions, character sets, and compatibility layers.

How to Fix

  • Replace raw MySQL calls with `$wpdb` methods or higher-level WordPress APIs.
  • Use `$wpdb->prepare()` for dynamic values.
  • If a third-party library requires a database connection, isolate it and document why WordPress APIs cannot be used.

Affected Plugins

RankPluginScoreErrorsWarningsInstallsAddedUpdatedTop Issue
#1404 Solution155821,53210k+Non-prefixed class
#2Matomo Analytics – Powerful, Privacy-First Insights for WordPress191,993892100k+Exception output is not escaped
#3Brizy – Page Builder2058572660k+Output is not escaped
#4Duplicator – Backups & Migration Plugin – Cloud Backups, Scheduled Backups, & More202,8791,9791m+Non-prefixed global variable
#5wpDataTables – WordPress Data Table, Dynamic Tables & Table Charts Plugin211,8291,53460k+Output is not escaped
#6WP Umbrella: Security Backup Restore & Monitoring221,0011,19180k+Exception output is not escaped
#7WP BackItUp Community Edition232579896k+Non-prefixed global variable
#8WP STAGING – Backups & Restore, Migration & Clone Plugin – Cloud Backups, Scheduled Backups231,5801,786100k+Non-prefixed global variable
#9Free 1-Click WordPress Migration24224244300Direct Query
#10Backuply – Backup, Restore, Migrate and Clone24729553600k+Non-prefixed global variable
#11Softaculous241155010k+file system operations fread
#12MapSVG – Vector maps, Image maps, Google Maps2692561k+Missing direct file access protection
#13EZ SQL Reports Shortcode Widget and DB Backup27165158500Output is not escaped
#14User Spam Remover31115141k+Output is not escaped
#15PW WooCommerce Bulk Edit3421914920k+Unsafe printing function