DB_common::quoteSmart()

DB_common::quoteSmart() -- Formats input so it can be safely used as a literal

Synopsis

mixed quoteSmart (mixed $in)

Description

Format input so it can be safely used as a literal in a query. Literals are values such as strings or numbers which get utilized in places like WHERE, SET and VALUES clauses of SQL statements.

The format returned depends on the PHP data type of input and the database type being used.

Parameter

mixed $in

the input to be quoted

Return value

mixed - the formatted data

The format of the results depends on the input's PHP type:

Note

This function can not be called statically.

Function available since: Release 1.6.0

Example

See

quoteIdentifier(), escapeSimple()