that's on purpose. WYWIWYG mode changes the normal event bindings so that , eg, [CTRL]+[B] turns the selection bold.
Originally Posted by sirajul
i don't think you can bind events on editable sub-tags.
also, using many contentEditables will get you in a heap of trouble quick once people start adding new lines.
that's not to say you can't watch the event on sub-tags, you just can't directly bind them.
Event delegation works fine, at least in a quick mini-test i just completed:
<div id="editor" contentEditable=true>
<code> this is a line of code</code>
<code> this is another line of code</code>
alert( t.outerHTML );