Embedding flash files in a text editor
I am trying to embed a Flash widget inside a text editor ( http://code.google.com/p/lwrte/ ) by adding a tag to an iframe HTML using the mozilla.insertHTML function ( http://www.mozilla.org/editor/ midas-spec.html ), but for some reason it never shows up - with firebug I can see that the embedding tag is there, but it stripped the closing tag.
any suggestions? how do other RTEs do it?
thank
IE and Firefox do not support Flash or any other plugin inside an editable tag.
What other editors (like TinyMCE or CKEditor ) is that they embed a placeholder image which is replaced with the appropriate object / embed tags when the form is submitted.
For example, a placeholder image for CKEditor looks like this:
<img class="cke_flash"
src="http://ckeditor.com/apps/ckeditor/3.0.1/images/spacer.gif?t=99GE"
_cke_realelement="%3Ccke%3Aobject%20codebase%3D%22http%3A%2F(...)"
alt="Flash Animation" _cke_real_element_type="flash"
_cke_resizable="true"/>
As you can see, they urlencode the entire object tag in the _cke_realelement attribute.
source to share