You are here

function _antispam_translate_query in AntiSpam 6

Same name and namespace in other branches
  1. 7 antispam.module \_antispam_translate_query()

Expand query for debugging purposes.

Parameters

string SQL statement.:

mixed array or variable list of arguments.:

2 calls to _antispam_translate_query()
_antispam_comment_form_validate in ./antispam.module
Comment form validate callback; check for spambots.
_antispam_node_form_validate in ./antispam.module
Node form validate callback; check for spambots.

File

./antispam.module, line 1143

Code

function _antispam_translate_query($query) {
  $args = func_get_args();
  array_shift($args);
  $query = db_prefix_tables($query);
  if (isset($args[0]) && is_array($args[0])) {

    // 'All arguments in one array' syntax
    $args = $args[0];
  }
  _db_query_callback($args, TRUE);
  $query = preg_replace_callback(DB_QUERY_REGEXP, '_db_query_callback', $query);
  return $query;
}