Hey,
I am using CKEDITOR to get input from user,I am saving generated HTML in database, i save html in database with following code:
<script>CKEDITOR.replace(\''+slide_instance+'\');CKEDITOR.add<\/script>
trim(htmlspecialchars(Generated HTML from CKEDITOR))
For some reason i have to pull html from database and set it to CKEDITOR with setData, I m using following code,
'<script>CKEDITOR.replace(\'desc'.$slide_no.'\').setData(\''.htmlspecialchars_decode($data6['html']).'\', function(){this.checkDirty();});</script>'
ISSUE: When html is very basic and simple without linebreaks or images, then it works fine but when i put line breaks and images in CKEDITOR,it shows exeption SyntaxError: unterminated string literal .Please replay to sort out this issue.