I have the following code:
var newHTML = "<p><span style='color: " + _color2[index] + "; background-color:" + _color[index] + "'><strong>" + _idMember[index] + ":</strong> </span></p>";
var newElement = CKEDITOR.dom.element.createFromHtml(newHTML, editor1.document);
editor1.insertElement(newElement);
Basically the code is writing the start of a conversation where you have the member's name in bold followed by a colon and a space. I then want the text position to be on the same line so that I can start typing the contents of the conversation.
This was all fine in CKEditor 3.6.3. But today I upgraded to CKEditor 4.3.1.
I'm able to insert the paragraph successfully. However CKEditor inserts an extra paragraph element below it and puts the cursor inside that element:
<p> </p>
I don't mind the extra element if that's the way things are done in CKEditor now. But how do I modify my code so that the cursor is situated between the and </span> in my element code?
