THE WORLD'S LARGEST WEB DEVELOPER SITE

PHP stripcslashes() Function

❮ PHP String Reference

Example

Remove the backslash in front of "World!":

<?php
echo stripcslashes("Hello \World!");
?>
Run example »

Definition and Usage

The stripcslashes() function removes backslashes added by the addcslashes() function.

Tip: This function can be used to clean up data retrieved from a database or from an HTML form.


Syntax

stripcslashes(string)

Parameter Description
string Required. Specifies the string to check

Technical Details

Return Value: Returns the unescaped string
PHP Version: 4+

❮ PHP String Reference