hi there! i want to ask if someone in here got an idea on how to remove the \ in apostrophes? because everytime i access content in my database and if it has ' it also displays \ for example cricket\'s should be crickets
You can use the function stripslashes - http://us2.php.net/stripslashes Use it like this: <?php $var = "cricket\'s"; $var = stripslashes($var); echo $var; ?> PHP:
The reason it does it is to sanitize user input to stop anybody executing their own code on your database. Just use stripslashes() on all output like the person above me said.