DB_common::escapeSimple() -- Escapes a string according to the current DBMS's standards
Описание
Escape a string according to the current DBMS's standards.
Параметр
- string
$str
the input to be escaped
Возвращаемое значение
string - the escaped string
Заметка
Эта функция не должна вызываться статически.
Function available since: Release 1.6.0
Пример
Пример 34-1. Using escapeSimple() <?php
// Once you have a valid DB object named $db...
$name = "all's well";
$sql = "SELECT * FROM clients WHERE name = '"
. $db->escapeSimple($name) . "'";
$res =& $db->query($sql);
?> |
|
HIVE: All information for read only. Please respect copyright! |
|