@@ 419-429 (lines=11) @@ | ||
416 | $db_string .= "\n\t\t\tORDER BY null"; |
|
417 | } |
|
418 | ||
419 | if (empty($db_values['security_override']) && (!empty($db_values) || strpos($db_string, '{db_prefix}') !== false)) |
|
420 | { |
|
421 | // Pass some values to the global space for use in the callback function. |
|
422 | $db_callback = array($db_values, $connection); |
|
423 | ||
424 | // Inject the values passed to this function. |
|
425 | $db_string = preg_replace_callback('~{([a-z_]+)(?::([a-zA-Z0-9_-]+))?}~', 'smf_db_replacement__callback', $db_string); |
|
426 | ||
427 | // This shouldn't be residing in global space any longer. |
|
428 | $db_callback = array(); |
|
429 | } |
|
430 | ||
431 | // Debugging. |
|
432 | if (isset($db_show_debug) && $db_show_debug === true) |
@@ 383-393 (lines=11) @@ | ||
380 | if (empty($modSettings['disableQueryCheck']) && strpos($db_string, '\'') !== false && empty($db_values['security_override'])) |
|
381 | smf_db_error_backtrace('Hacking attempt...', 'Illegal character (\') used in query...', true, __FILE__, __LINE__); |
|
382 | ||
383 | if (empty($db_values['security_override']) && (!empty($db_values) || strpos($db_string, '{db_prefix}') !== false)) |
|
384 | { |
|
385 | // Pass some values to the global space for use in the callback function. |
|
386 | $db_callback = array($db_values, $connection); |
|
387 | ||
388 | // Inject the values passed to this function. |
|
389 | $db_string = preg_replace_callback('~{([a-z_]+)(?::([a-zA-Z0-9_-]+))?}~', 'smf_db_replacement__callback', $db_string); |
|
390 | ||
391 | // This shouldn't be residing in global space any longer. |
|
392 | $db_callback = array(); |
|
393 | } |
|
394 | ||
395 | // Debugging. |
|
396 | if (isset($db_show_debug) && $db_show_debug === true) |