homepage Welcome to WebmasterWorld Guest from 54.161.191.254
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member
Visit PubCon.com
Home / Forums Index / Code, Content, and Presentation / Flash and Shockwave
Forum Library, Charter, Moderator: open

Flash and Shockwave Forum

    
Having trouble with the swfobject.js script
Can't get it to show my flash file
WilMoya




msg:3039138
 8:12 pm on Aug 8, 2006 (gmt 0)

I've tried several things. Everything seems ok, but when I apply the script to the page, the Flash file doesn't show. When I remove the script, everything's OK. I would appreciate tips on any errors in my code. Here's a sample:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Untitled Document</title>
<script type="text/javascript" src="swfobject.js"></script>
<meta name="robots" content="noindex,nofollow" />
</head>

<body>
<div id="flashcontent">
This is the text behind the movie.</div>

<script type="text/javascript">
var fo = new SWFObject("swf/banner1.swf", "banner1", "420", "147", "6", "#FFFFFF");
fo.addVariable("variable", "varvalue");
fo.write("flashcontent");
</script>

</body>
</html>

Thanks,
Wil Moya

[edited by: WilMoya at 8:25 pm (utc) on Aug. 8, 2006]

 

dareRock




msg:3046489
 3:27 am on Aug 15, 2006 (gmt 0)

change 'banner1' in your SWFObject constructor to 'flashcontent'

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / Flash and Shockwave
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved