Dear friends, I need to insert textarea data into mysql and retrieve it in web page. so please tell me how to format it. Thanks
Always use addslashes($var) PHP: when adding variables to your database. You can use stripslashes($row['var']) when you're displaying them again although it might work without this.
No, mysql_real_escape_string is better if you can use it. They are nearly functionally identical however mysql_escape_string() does not take a connection argument and does not respect the current charset setting - and you want it to respect the current charset setting. It is advised you use mysql_real_escape_string however because mysql_escape_string is deprecated. Dan