I am having trouble initializing two instances of tinymce
on my webpage.
Even after following the guidance provided in this particular thread, I am unable to get it working. Could it be possible that I need to introduce a timeout between initializing the first instance (io) and then proceeding with the initialization process for the second instance (co)?
var io = {
selector:"#auth_info_intro textarea",
...,
setup:function(ed){
ed.on("init",function(e){
tinyMCE.activeEditor.setContent(obj.INFO.INTRO.TEXT);
});
}
};
var co = {
selector:"#auth_info_conclude textarea",
...,
setup:function(ed){
ed.on("init",function(e){
tinyMCE.activeEditor.setContent(obj.INFO.CONCLUDE.TEXT);
});
}
};
tinymce.init(io);
tinymce.init(co);
Running the code above results in an error message:
Uncaught TypeError: Cannot read property 'body' of undefined
.
What could possibly be the issue here?