addcslashes() and backcslashes()
The addcslashes() function return a string with backslashes in front of the specified character
Syntax
string addcslashes( string $str,string $charlsit)
Example
Output:
wel\come to india
The backcslashes() function removed the character added from addcslashes() functionThe addcslashes() function return a string with backslashes in front of the specified character
Syntax
string addcslashes( string $str,string $charlsit)
Example
<?php $str="welcome to india"; echo $str; echo addcslashes($str,'c'); ?> |
Output:
wel\come to india
backcslashes()
Syntax:
backcslashes(string)
<?php echo backcslashes("wel\come to india"); ?> |
welcome to india
0 comments:
Post a Comment