Ticket #669 (new enhancement)
Proposition for FlashEdit plugin - for comment
| Reported by: | benDOTsimkinsATintsoftDOTch | Owned by: | gogo |
|---|---|---|---|
| Priority: | normal | Milestone: | Version 1.0 |
| Component: | Plugins | Version: | |
| Severity: | normal | Keywords: | flash plugin edit |
| Cc: |
Description
Having played around with flash objects in the xinha editor, and getting mighty frustrated in the process (Firefox seems to lose the flash object, even if you do a innerHTML=innerHTML), I discovered Geoff Stearns' FlashObject (http://blog.deconcept.com/flashobject/).
To explain briefly, the logic of the flash object is to have a div containing a 'no flash' message, followed by a script which loads the flash dynamically at 'runtime' - the html sent to the browser looks like this :
<div class="FlashOverlay" id="FlashId1" style="height: 100px; width: 100px;">
Sorry, you do not appear to have the flash plugin installed.
</div>
<script type="text/javascript">
var fo = new FlashObject("http://www.mysite.com/flash.swf", "FlashId1", "100", "100", "6", "#FF6600");
fo.addParam("quality", "high");
fo.addParam("wmode", "opaque");
fo.addParam("align", "left");
fo.addParam("play","true");
fo.addParam("loop","true");
fo.addParam("menu","false");
fo.addParam("devicefont","true");
fo.write("FlashId1");
</script>
Opting for this approach allows me to 1) Handle non-flash (and non-javascript) browsers and 2) Work around the problems with editing flash content in Xinha.
So this plugin doesn't directly edit flash (should I change the name?), but rather the DIV and SCRIPT elements necessary for the FlashObject.js code.
There are a couple of dependencies/hacks, these are detailed at the top of the FlashEdit.js file.
(Only tested so far on IE6 and FF1.5)
I welcome comments/suggestions (especially for removing the hacks).
{I have to submit this before being able to add a file?}
