Miko
Miko

Reputation: 2633

Inserting text from textarea to mysql table

I have a form with a textarea field. When i add some html code. It's inserting into the table properly but with extra slashes. Before inserting the code i used the mysql_real_escape_string function and stipslashes function. But still no use. The data adding with the slashes. What's the problem ? Is i have to use any other functions??

Upvotes: 0

Views: 510

Answers (1)

Dejan Marjanović
Dejan Marjanović

Reputation: 19380

You should use stripslashes() when you are reading from the database.

Maybe you have magic_quotes_gpc on, please paste some code.

Upvotes: 1

Related Questions