Gen. partnerAlgotech

PHP function addcslashes()

Quote string with slashes in a C style

|
September 11, 2019

Availability in PHP 4.0

Quote string with slashes in a C style

Parameters

Parameter Data type Default value Note
$str string not String to be escaped.
$charlist string not List of characters to be escaped. If charlist contains \n, \r, etc., they are converted to C style, while other non-alphanumeric characters with ASCII codes lower than 32 and higher than 126 are converted to octal representation.

Return values

string

the escaped string.

Other resources

Official addcslashes documentation

Loading comments...

Stay in the loop

Subscribe to our newsletter and get the latest cybersecurity news delivered straight to your inbox.

Your data is safe. You can unsubscribe from the newsletter at any time.