BobtheKing Dot Com

Putting the Point in Pointless.

More of Jeramey's photos

Sunday, January 04, 2009

SWFObject Is Not Defined

If you’re having trouble with SWFObject.js and getting a “n is not defined” error, you’re probably not alone.

The mistake I made was not creating a <div> tag with the id name specified in my SWF creation script.

I needed this…

<div id="flashcontent1">

For this to work

<script type="text/javascript">
    var so = new SWFObject("mslide_show.swf", "mymovie", "211", "319", "6", "#FFFFFF");
    so.addVariable("quality", "high"); 
    so.addVariable("menu", "false"); 
    so.addVariable("pluginurl", "");


Post a Comment

<< Home