ExecCommand offers a way to bold text inside iFrame, make it italic, underline it etc.
But it’s missing an option to create <cite> or <strong> or <em> (there is formatBlock but only for block elements and not inline ones).
I’d like to use ExecCommand function for creating <cite> – is there any way to achieve this? And obviously I want to maintain flawless parsing like in case of bold and not something like surroundContents which will fail when you use it twice on the same selection.
I’m looking for a definition of ExecCommand bold command or a way to use existing commants to flawlessly add <cite>. Any suggestions? I couldn’t extract it from browser’s functions. It says “native code” when I try to do that.
I see that CKEditor was mentioned in one of previous comments 🙂 So this is how we handle executing commands:
strongand secondborspanwith inline style).