WordPress.DB.DirectDatabaseQuery.DirectQuery
Direct Query
The plugin runs a direct database query instead of using a higher-level WordPress API or cache-aware pattern.
Why It Shows Up
Plugin Check found `$wpdb` access that queries the database directly, changes schema, or bypasses normal caching expectations.
Why It Matters
Direct queries can be correct, but they are easier to make unsafe, slower at scale, and harder for WordPress to cache or filter.
How to Fix
- Use WordPress APIs such as post, term, metadata, option, or user functions when they fit the task.
- If direct SQL is necessary, prepare dynamic values and add a clear caching strategy for repeated reads.
- Keep schema changes in activation or upgrade routines and make them idempotent.
References
Affected Plugins
| Rank | Plugin | Score | Errors | Warnings | Installs | Added | Updated | Top Issue |
|---|---|---|---|---|---|---|---|---|
| #701 | SEO Engine – Smart SEO with AI, Schema & Redirection for WordPress | 24 | 239 | 304 | 1k+ | Direct Query | ||
| #702 | SEOKEY – Powerful SEO plugin with Expert Insights and SEO Audit | 24 | 605 | 928 | 1k+ | Non-prefixed global variable | ||
| #703 | SEO Ultimate | 24 | 437 | 269 | 10k+ | Output is not escaped | ||
| #704 | Servebolt Optimizer | 24 | 1,958 | 681 | 1k+ | Text Domain Mismatch | ||
| #705 | Service Box Slider | 24 | 618 | 1,410 | 500 | Non-prefixed global variable | ||
| #706 | Share This Image | 24 | 744 | 1,582 | 1k+ | Non-prefixed global variable | ||
| #707 | ShiftController Employee Shift Scheduling | 24 | 358 | 196 | 700 | Output is not escaped | ||
| #708 | Shortcodes Ultimate – Content Elements | 24 | 656 | 1,552 | 400k+ | Non-prefixed global variable | ||
| #709 | ShortPixel Adaptive Images – WebP, AVIF, CDN, Image Optimization | 24 | 926 | 322 | 10k+ | Output is not escaped | ||
| #710 | Simple Membership | 24 | 2,297 | 1,734 | 40k+ | Unsafe printing function | ||
| #711 | Simple Social Media Share Buttons – Social Sharing for Everyone | 24 | 468 | 101 | 20k+ | Output is not escaped | ||
| #712 | SiteGuard WP Plugin | 24 | 359 | 350 | 500k+ | Output is not escaped | ||
| #713 | Sitepact's Contact Form 7 Extension For Klaviyo | 24 | 541 | 1,412 | 500 | Non-prefixed global variable | ||
| #714 | SKT Templates – 100% Free Templates for Elementor & Gutenberg | 24 | 553 | 1,353 | 20k+ | Non-prefixed global variable | ||
| #715 | Slider Hero with Video Background, Animation | 24 | 36 | 905 | 3k+ | Non-prefixed hook name | ||
| #716 | Video Slider – Slider Carousel | 24 | 208 | 2,203 | 3k+ | Request data is not unslashed | ||
| #717 | Slideshow Gallery LITE | 24 | 896 | 414 | 5k+ | Output is not escaped | ||
| #718 | Smart Variations Images & Swatches for WooCommerce | 24 | 990 | 1,486 | 1k+ | Non-prefixed global variable | ||
| #719 | MoreConvert Wishlist for WooCommerce | 24 | 3,681 | 629 | 9k+ | Text Domain Mismatch | ||
| #720 | Sokol: Smart WooCommerce Search | 24 | 599 | 1,551 | 6k+ | Non-prefixed global variable | ||
| #721 | SMS Alert – SMS & OTP for WooCommerce, Order Notifications & Abandoned Cart Recovery | 24 | 832 | 1,891 | 3k+ | Non-prefixed global variable | ||
| #722 | SiteOrigin Widgets Bundle | 24 | 605 | 455 | 400k+ | Output is not escaped | ||
| #723 | Social Media Auto Publish | 24 | 1,468 | 713 | 6k+ | Unsafe printing function | ||
| #724 | Softaculous | 24 | 115 | 50 | 10k+ | file system operations fread | ||
| #725 | SpiceBox | 24 | 828 | 1,816 | 20k+ | Non-prefixed global variable | ||
| #726 | Spider Elements – Premium Elementor Widgets & Addons Library | 24 | 542 | 1,555 | 500 | Non-prefixed global variable | ||
| #727 | Spotlight Social Feeds – Block, Shortcode, and Widget | 24 | 411 | 147 | 60k+ | Output is not escaped | ||
| #728 | Squad Modules Lite – Free Divi 5 & Divi 4 Modules for Divi Builder | 24 | 605 | 1,472 | 1k+ | Non-prefixed global variable | ||
| #729 | GEO Plugin by Squirrly SEO | 24 | 1,195 | 224 | 30k+ | Missing Translators Comment | ||
| #730 | StreamWeasels Online Status Bar | 24 | 555 | 1,349 | 500 | Non-prefixed global variable | ||
| #731 | StreamWeasels YouTube Integration | 24 | 544 | 1,384 | 1k+ | Non-prefixed global variable | ||
| #732 | Stripe Payment Forms by WP Simple Pay – Accept Credit Card Payments + Subscriptions with Stripe | 24 | 634 | 652 | 9k+ | Exception output is not escaped | ||
| #733 | Sugar Calendar – Events Calendar, Event Tickets, and Events Management Platform | 24 | 428 | 956 | 10k+ | Output is not escaped | ||
| #734 | Sunshine Photo Cart – Client Photo Gallery & Photo Proofing for Photographers | 24 | 360 | 1,472 | 1k+ | Nonce verification recommended | ||
| #735 | Surbma | GDPR Proof Cookie Consent & Notice Bar | 24 | 825 | 1,309 | 500 | Non-prefixed global variable | ||
| #736 | Tainacan | 24 | 138 | 592 | 1k+ | Direct Query | ||
| #737 | Team Members – Multi Language Supported Team Plugin | 24 | 2,081 | 11,206 | 7k+ | Non-prefixed global variable | ||
| #738 | Templately – Elementor & Gutenberg Template Library: 6500+ Free & Pro Ready Templates And Cloud! | 24 | 167 | 225 | 300k+ | Nonce verification recommended | ||
| #739 | The Plus Addons for Elementor – Addons for Elementor, Page Templates, Widgets, Mega Menu, WooCommerce | 24 | 12,049 | 494 | 100k+ | Text Domain Mismatch | ||
| #740 | TI WooCommerce Wishlist | 24 | 467 | 546 | 100k+ | Output is not escaped | ||
| #741 | Tiered Pricing Table for WooCommerce | 24 | 606 | 1,990 | 10k+ | Non-prefixed global variable | ||
| #742 | Timber | 24 | 85 | 128 | 20k+ | Non-prefixed hook name | ||
| #743 | Tutor LMS – eLearning and online course solution | 24 | 328 | 4,409 | 100k+ | Non-prefixed global variable | ||
| #744 | Ultra Addons for Contact Form 7 | 24 | 1,543 | 452 | 60k+ | Text Domain Mismatch | ||
| #745 | Ultimate Maps by Supsystic | 24 | 1,034 | 374 | 10k+ | Non Singular String Literal Domain | ||
| #746 | Ultimate Member – User Profile, Registration, Login, Member Directory, Content Restriction & Membership Plugin | 24 | 938 | 2,935 | 200k+ | Non-prefixed global variable | ||
| #747 | Ultimate Post Kit Addons for Elementor | 24 | 183 | 412 | 30k+ | Missing nonce verification | ||
| #748 | Ultimate Product Catalog | 24 | 554 | 525 | 5k+ | Unsafe printing function | ||
| #749 | Ultimate WP Mail | 24 | 400 | 546 | 700 | Unsafe printing function | ||
| #750 | Unlimited Elements For Elementor | 24 | 710 | 2,093 | 300k+ | Non-prefixed global variable |