Name
addcslashes
Synopsis
string addcslashes(stringstring
, stringcharacters
)
Escapes instances of characters
in
string
by adding a backslash before them.
You can specify ranges of characters by separating them by two
periods; for example, to escape characters between a
and q
, use "a..q"
. Multiple characters and ranges can
be specified in characters
. The addcslashes( )
function is the inverse of
stripcslashes( )
.
Get Programming PHP, 2nd Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.