<HTML><BODY style="word-wrap: break-word; -khtml-nbsp-mode: space; -khtml-line-break: after-white-space; ">in the latest version of swfobject, the write() method will return true or false depending on whether the flash content was written...<DIV><BR class="khtml-block-placeholder"></DIV><DIV>so you could do this:</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>if (!so.write('content')) {</DIV><DIV><SPAN class="Apple-tab-span" style="white-space:pre">   </SPAN>// flash was not written, do something</DIV><DIV>} else {</DIV><DIV><SPAN class="Apple-tab-span" style="white-space:pre">        </SPAN>// flash was written, do something else</DIV><DIV>}</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV><BR><DIV><DIV>On May 30, 2006, at 9:15 AM, Guillaume wrote:</DIV><BR class="Apple-interchange-newline"><BLOCKQUOTE type="cite"><DIV>Hi,</DIV> <DIV> </DIV> <DIV>Ive been using swfobject, which is very handy - And i have been asked to do some flash detection (for people coming with a Flash 7 player, to play Flash 8 swfs) - in Javascript, for various reasons from my manager. Since when you put into SWFObject() the parameter to write for a flash "8" swf, if someone (under IE or firefox) got Flash Player 7, it will not write anything into the "Flashcontent" div, here is my kind of solution , and at least compared to scripts you can find here and there, this one looks to work well with ffox. </DIV> <DIV> </DIV> <DIV><script></DIV> <DIV>function returnobj(id) {<BR>  if (document.getElementById) {<BR>    return document.getElementById(id);<BR>  } else if (document.all) {<BR>    return document.all[id];<BR>  } else if (document.layers) {<BR>    return document.layers[id];<BR>  } else {<BR>    return false;<BR>  }<BR>}<BR> </DIV> <DIV><P>function didFlashWork()<BR>{</P><P>var target = returnobj("Flashcontent");</P><P>if(target) {<BR>if(target.innerHTML.length<2) {</P><P> target.innerHTML = "Sorry you do not have flash player/the good version of flash player.. please see <a href='<A href="http://www.adobe.com'">http://www.adobe.com'</A>>Here</a> to dl a flash player.."; </P><P>}</P><P>}</P><P>}</P><P></script></P><DIV> <BR class="khtml-block-placeholder"></DIV><P>(...)</P><P><html></P><P><body></P><P><script type="text/javascript" src="swfobject.js"></script><BR></P><P><div id="Flashcontent"></div><BR>var so = new SWFObject("test.swf","mymovie", 200, 200, "8", "#000000");</P><P>so.write("Flashcontent");<BR>didFlashWork();<BR></script></P><DIV> <BR class="khtml-block-placeholder"></DIV><DIV> <BR class="khtml-block-placeholder"></DIV><DIV> <BR class="khtml-block-placeholder"></DIV><DIV> <BR class="khtml-block-placeholder"></DIV><DIV> <BR class="khtml-block-placeholder"></DIV></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">_______________________________________________</DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; ">SWFObject mailing list</DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><A href="mailto:SWFObject@lists.deconcept.com">SWFObject@lists.deconcept.com</A></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><A href="http://lists.deconcept.com/listinfo.cgi/swfobject-deconcept.com">http://lists.deconcept.com/listinfo.cgi/swfobject-deconcept.com</A></DIV> </BLOCKQUOTE></DIV><BR></DIV></BODY></HTML>