Flash in master file header

A place for discussion about skinning and design. Before posting questions here you should review the documentation about creating skins.

This thread is closed to new posts. You must sign in to post in the forums.
8/23/2010 11:06:15 AM
Gravatar
Total Posts 11

Flash in master file header

I am struggleing to get a flash movie to work in the header of my master file. Odd thing is that it will work in any other file withing the site that is static html or aspx. The header also work in the site error page if I do a bogus search for "This is driving me crazy" <- just an example to generate the error page.

I am using a very simple way of embedding the movie:
<script type="text/javascript" src="<%= SkinBaseUrl %>swfobject.js"></script>
<script type="text/javascript">
var flashvars = {};
flashvars.settingsXML = "<%= SkinBaseUrl %>settings.xml";
var params = {};
params.scale = "noscale";
params.salign = "tl";
params.wmode = "transparent";
params.allowfullscreen = "true";
var attributes = {};
swfobject.embedSWF("<%= SkinBaseUrl %>banner.swf", "BannerDiv", "600", "260", "9.0.0", false, flashvars, params, attributes);
</script>

<div id="BannerDiv"></div>

Using the SkinBaseUrl gets the right paths so I am at a loss getting this to work. Has anyone ran into this problem then overcame it. I have read some other posts but was unable to resolve the issue. Any help is appreciated.

Thanks,

Steve

8/23/2010 12:07:52 PM
Gravatar
Total Posts 11

Re: Flash in master file header

I have found that http://www.flashxml.net/banner-rotator.html may be my issue. The way that it pulls the images into the movie is the problem that I am having. While the banner works great on static html, aspx, and the error page is odd. If I use a static flash file and not the banner rotator then the static file works just lfine in the layout.master. Anyone here good with flash? I am not . This flash uses a settings.xml and images.xml. The images.xml tells the movie where the images to be cycled are. I have tried relative and absolute path in the images.xml file. The banner can be downloaded for free.

Thanks,
Steve

8/23/2010 12:21:18 PM
Gravatar
Total Posts 18439

Re: Flash in master file header

I'm no Flash expert either, but I suspect it has to do with where it expects the xml file to be located. It may expect it to be relative to the .swf location or it may expect it to be relative to the site root or some other scheme. If the xml file is in the same folder as the flash you may only need to specify the file name.

To make it as close as possible to the example html you should try putting the .swf and .xml files in the very root of the site and then just specify the urls like /banner.swf, /settings.xml, try it with and without the /, but I suspect it needs the /

Also, you don't need to load swfobject script yourself, it is included with mojoPortal, just set <portal:ScriptLoader ... IncludeSwfObject="true"

Hope it helps,

Joe

You must sign in to post in the forums. This thread is closed to new posts.