i have a form where a user can type a message into a textarea, it's stored in a variable, and the PHP page emails it out to other users. the problem i have is anytime the user types a ' or a " the PHP page or something puts a \ in front of them and its really annoying and unprofessional. is there anyway around this?
~JOSH
I think there is the function "addslashes" active or it's done standard by PHP try to use "urlencode" bedore you post the variable.
i tried urlencode() but that just turned the ' and " into %5C and %27 which is even worse than the ' and "
i also tried htmlentities() and htmlspecialchars() but they replace ' and " with ' and what not which is just converted back to ' and " when the HTML is parsed.
I'm right with that the problem is in the delivered mail?
There is also a "stripslashes" function....
well, that was easy, the stripslashes did it.
thanks a million, i love this board