homepage Welcome to WebmasterWorld Guest from 54.147.196.159
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Pubcon Platinum Sponsor 2014
Home / Forums Index / Code, Content, and Presentation / Flash and Shockwave
Forum Library, Charter, Moderator: open

Flash and Shockwave Forum

    
weather widget not showing in FF
tonynoriega

WebmasterWorld Senior Member 5+ Year Member



 
Msg#: 3806314 posted 7:03 pm on Dec 12, 2008 (gmt 0)

ok, i know i should know this, but i have tried several .js files to make this flash object play in FF... IE7 works fine...

what do i need to do to get this to work?

<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,0,0" type="application/x-shockwave-flash" width="184px" height="99px" id="InsertWidget_38be7006-abd0-49d2-98a3-626b2ff615d3" align="middle">
<param name="movie" value="http://example.com/syndication/flash/wrapper/InsertWidget.swf"/>
<param name="quality" value="high" />
<param name="wmode" value="transparent" />
<param name="menu" value="false" />
<param name="flashvars" value="r=2&appId=38be7006-abd0-49d2-98a3-626b2ff615d3" />
<param name="allowScriptAccess" value="sameDomain" /> <br>
<embed src="http://example.com/syndication/flash/wrapper/InsertWidget.swf" name="InsertWidget_38be7006-abd0-49d2-98a3-626b2ff615d3" width="184px" height="99px" quality="high" menu="false" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" wmode="transparent" align="middle" allowScriptAccess="sameDomain" flashvars="r=2&appId=38be7006-abd0-49d2-98a3-626b2ff615d3" />
</object>

[edited by: eelixduppy at 12:31 am (utc) on Dec. 13, 2008]

 

rocknbil

WebmasterWorld Senior Member rocknbil us a WebmasterWorld Top Contributor of All Time 10+ Year Member



 
Msg#: 3806314 posted 2:56 pm on Dec 14, 2008 (gmt 0)

At fist glance would say it's expecting a closing </embed> tag, but that's still invalid code (embed nested in object and embed is deprecated.)

Try this. Download and place a copy of SWFobject [blog.deconcept.com] in the directory. No edits or changes, just include it as below.

Head of document (or external JS for the second block of Javascript:)


<script type="text/javascript" src="swfobject.js"></script>
<script type="text/javascript">
var myFlash = new swfobject('http://example.com/syndication/flash/wrapper/InsertWidget.swf',
'InsertWidget_38be7006-abd0-49d2-98a3-626b2ff615d3', '184', '99', '9', '#ffffff');
// Quality determined by the "9" above
myFlash.addParam("wmode", "transparent");
myFlash.addParam("menu", "false");
myFlash.addParam("allowScriptAccess","SameDomain");
myFlash.addVariable("flashvars", "r=2&amp;appId=38be7006-abd0-49d2-98a3-626b2ff615d3");
window.onload = function() {
if (document.getElementById('my-fla-div')) {
myFlash.write('my-fla-div');
}
};
</script>

In document where you want it to display:

<div id="my-fla-div"><img src="screen-capture-of-widget.jpg"></div>

1. Initially an image loads when page loads, in case Flash is not present.
2. If Flash plugin is present, JS writes flash to div.

Be sure "flashvars" is the variable expected by the flash object. If it's not, change "addVariable" to this:

myFlash.addVariable("r", "2");
myFlash.addVariable("appId","38be7006-abd0-49d2-98a3-626b2ff615d3");

You may have to fiddle with it a bit, but this is a very reliable cross browser approach.

tonynoriega

WebmasterWorld Senior Member 5+ Year Member



 
Msg#: 3806314 posted 5:15 pm on Dec 15, 2008 (gmt 0)

found the problem. resolved. thanks

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