EDIT:
EDIT 2:
EDIT 3:
EDIT 4:
Background:
contents
edinstance.getData()
editorinstance
edinstance.getData()
.val()editorinstance.updateElement()
EDIT 2:
EDIT 3:
edinstance.destroy(); alert(edinstance.getData()); //Still returns the old contents of the editor
edinstance = null; //Tried setting the instance variable to null before getting the new instance from the textarea
edinstance = $('textarea#contents').ckeditorGet(); //This causes an error "edinstance is null" EDIT 4:
Background:
contents
"<textarea id=\"contents\" class=\"article\">" . $articleContent->getBody() . "</textarea>"edinstance
function attachEditor()
{
if(typeof edinstance != "undefined")
{
edinstance.destroy();
//alert('editor destroyed');
}
$('textarea#contents').ckeditor();
edinstance = $('textarea#contents').ckeditorGet();
}Scenario:edinstance.getData()
editorinstance
edinstance.getData()
.val()editorinstance.updateElement()
i.contentWindow is null
[] if(c){var u=n.getDocumentElement().con...on(){return this.$.childNodes.length; //ckeditor.js line 19
Re: getData() returns old contents after the first time (PHP
Could you publish a test case online?
Re: getData() returns old contents after the first time (PHP
While the issue isn't that urgent, I was hoping this would be a common problem due to some beginner oversight or something.
Using the Safari Activity Log I observed that each time I perform the AJAX call, the CKEditor resources were being loaded again and again on top of the ones that were already there. Could my problem be caused by the fact that my original form elements still stay present somewhere in the DOM even after I inject new ones into the same div ? Or is that just a harmless side-effect of using AJAX ?
Re: getData() returns old contents after the first time (PHP
http://dev.ckeditor.com/ticket/8226
Re: getData() returns old contents after the first time (PHP
Re: getData() returns old contents after the first time (PHP
so anyone who is getting frustrated on this issue just get the iframe data instead of using getData()
sample code
var iframe=$("iframe",parentnode);
var value=$("body",iframe.contents()).html();