jscrinc Posted June 3, 2010 Share Posted June 3, 2010 Hi I have installed a wysiwyg editor for my form and i wanted to insert an image, so i do and it works great, but when i go to submit it and call it back from the database its all wrong. Here is an example: Code before Submit: <h1>Enter your new post</h1><p>More of the example</p> <p><span><img src="http://lh4.ggpht.com/_Jq9BxxgyOnc/TAV-iAqGrJI/AAAAAAAAAA0/pVNbTVbYIuU/jscrinc.png" title="" align="right"></span><br></p> Code showing on call back: <h1>Enter your new post</h1><p>More of the example</p><p><span><img src=\"http://lh4.ggpht.com/_Jq9BxxgyOnc/TAV-iAqGrJI/AAAAAAAAAA0/pVNbTVbYIuU/jscrinc.png\" title=\"\" align=\"right\"> Image URL on call back: http://jscrgaming.co.uk/%22http://lh4.ggpht.com/_Jq9BxxgyOnc/TAV-iAqGrJI/AAAAAAAAAA0/pVNbTVbYIuU/jscrinc.png/%22.. Im wondering if its anything to do with the submitting of the form or not. Please Help James Quote Link to comment https://forums.phpfreaks.com/topic/203732-image-html-hasnt-submitted-correctly/ Share on other sites More sharing options...
PFMaBiSmAd Posted June 3, 2010 Share Posted June 3, 2010 http://us2.php.net/magic_quotes If the data contains escape characters \, either it was escaped an extra time (once by php due to magic_quotes_gpc and once by your code) when it was put into the database or it is being escaped (by php due to magic_quotes_runtime) when it is being retrieved from the database. If the escaping is done correctly (i.e. only your code is escaping the data once before it is put into the query), the escape characters \ are NOT present in the database. If the escape characters \ are present in the database, then magic_quotes_gpc is causing the problem. If the escape characters \ are NOT present in the database, then magic_quotes_runtime is causing the problem. Quote Link to comment https://forums.phpfreaks.com/topic/203732-image-html-hasnt-submitted-correctly/#findComment-1067139 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.