quotemeta()

It adds backslashes in front of some predefined characters in a string.

Example

<?php
echo quotemeta(“php(code)'”);
?>

Output

php(code)’

Share