This has been wearing me out for – ohh, DAYS! I suspect it’s a tiny bit of wrong syntax …. Please, please, can one of you experts help me spot the problem??? ?
Trying to write my first-ever totally standards-compliant page, I used Ian Hickson’s compliant Flash script (you can’t use the standard one because the <embed> tag doesn’t validate) from [url]http://ln.hixie.ch/?start=1081798064&order=-1&count=1
It works brilliantly.
However, I also want to deploy Colin Moock’s Flash & Javascript sniffer, ([url]http://www.moock.org/webdesign/flash/detection/moockfpi/
That means I have to turn Mr Hickson’s Flash script into a document.write segment in the sniffer script – am I explaining this OK?
My problem now is that the page won’t load properly in IE. It seems to be waiting for something else (1 item remaining).
Either script does the job 100% on its own – so there’s something wrong with the way I’ve put them together.
The problem [i]seems
Anyway, here’s the relevant part of my code:
[code]<script language=”javascript” type=”text/javascript”>
<!–
if (!useRedirect) {
if(hasRightVersion) {
var oeTags = “<object classid=”clsid:D27CDB6E-AE6D-11cf-96B8-444553540000″”
+” codebase=”http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0″”
+” width=”250″ height=”60″>”
+” <param name=”movie” value=”images/internet-grey.swf” />”
+” <param name=”quality” value=”high” />”
+” <param name=”SCALE” value=”exactfit” />”
//[if !IE]
+” <object data=”images/internet-grey.swf””
+” width=”250″ height=”60″ type=”application/x-shockwave-flash”>”
+” <param name=”quality” value=”high” />”
+” <param name=”SCALE” value=”exactfit” />”
+” <param name=”pluginurl” value=”http://www.macromedia.com/go/getflashplayer” />”
+” </object>”
//[endif]
+” </object>”;
document.write(oeTags);
}
else {
var alternateContent=
‘<a href=”IAB_Online_Marketing_in_2004.html”><img src=”/images/UKspendstatic.jpg” alt=”UK Online Marketing Data” width=”250″ height=”60″ border=”0″ /></a>’;
document.write(alternateContent); // insert non-flash content
}
}
//–>
</script>
<noscript>
<a href=”IAB_Online_Marketing_in_2004.html”><img src=”/images/UKspendstatic.jpg” alt=”UK Online Marketing Data” width=”250″ height=”60″ border=”0″ /></a>
</noscript>
Oh look, that’s funny! (There isn’t a smiley in my code; it was a colon and a D)
If anyone wants to see this in (flawed) action, it’s at [url]http://www.no-url.co.uk/index1.html
I am [b]stumped
Hope you can sort me out!
Thank you
Cherry