View Single Post
  #2  
Old 06-07-2013, 09:28 AM
Tequila's Avatar
Tequila Tequila is offline
The Grim One
 
Join Date: Jan 2009
Location: Souther Tier, New York State
Posts: 1,356
Gender: Female
Credits: 123,295
Tequila is on a distinguished road
Default

A quick google search pulled this up:
http://www.tinymce.com/forum/viewtopic.php?id=12092

Quote:
This is a bug but i created some cheat in php... Basically, /r/n is "new line" in html that can be read by tinymce, and some hosting company uses "addslashes" function to resolve sql injection...
In order to remove those slashes, you need to use "stripslashes", but it will also remove the slashes in "/r/n" so it will produce the string "rn". Therefore, that "rn" will appear as text in tinymce... (i used this also in <img> slashes problem)
To resolve that, you just have to add "replace_str" before sending it to database (replace 'rn' with '')....
like this >>>

stripslashes(str_replace('\r\n', '', mysql_real_escape_string($post['description'])))


hope this help... it works with me....
Last edited by rexjaysoncortez (2010-12-19 16:31:42)
Just have to add that code in. I'll let Hoffie know that this bug is still going...
__________________
Artist. Designer. Gamer. Mother.
[portfolio] [tarot] [Rune Hollow] [freebies]
Reply With Quote