Add überpowerful "query" filter, for SQL queries. fixes #2721

git-svn-id: https://develop.svn.wordpress.org/trunk@4619 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Mark Jaquith 2006-12-07 00:02:03 +00:00
parent c6ff4d8f99
commit c0b9ade921
1 changed files with 5 additions and 0 deletions

View File

@ -139,6 +139,11 @@ class wpdb {
// Basic Query - see docs for more detail
function query($query) {
// filter the query, if filters are available
// NOTE: some queries are made before the plugins have been loaded, and thus cannot be filtered with this method
if ( function_exists('apply_filters') )
$query = apply_filters('query', $query);
// initialise return
$return_val = 0;
$this->flush();