this is how I destroy CKEditor instance:
CKEDITOR.instances.Divname.destroy();
with Divname being id of the div.
but, how to destroy instance, if I use variable like this:
var x = "Divname";
CKEDITOR.instances.x.destroy();
It’ll give me x is undefined error.
running example:
http://jsfiddle.net/DBbYm/1/
please enable the instance (to attach editor), and then disable the instance (to destroy), and you’ll get the error.
Any advice to solve this?
In JS you could call members like this