briedis Posted October 30, 2008 Report Share Posted October 30, 2008 Ir textarea, no kuras tekstu glabāju mysql datubāzē. Izmantoju stripslashes(mysql_real_escape_string($_POST['teksts'])) Problēma ir tā, ka visi \n\r tiek pārtaisīti par "nr", bet ja neizmanto stripslashes, tad pirms katras pēdiņas ir slashs. Ko darīt, lai saglabātu line break'us, bet nesataisītu šmuci ar dubultiem backslashiem un backslashotām pēdiņām? Link to comment Share on other sites More sharing options...
andrisp Posted October 30, 2008 Report Share Posted October 30, 2008 Pirmkārt jau apmaini šīs fjas vietām. Tas ir: mysql_real_escape_string(stripslashes($_POST['teksts'])); Link to comment Share on other sites More sharing options...
briedis Posted October 30, 2008 Author Report Share Posted October 30, 2008 (edited) Klanos Tavā priekšā! Tiešām koda dievs!! :)) Edited October 30, 2008 by briedis Link to comment Share on other sites More sharing options...
Recommended Posts