Questions
Answer
How to specify the correct path in the embedding code of the SWFs
Generally, you must know that the path of the assets the SWF uses (the path of the images or videos specified in the XML file and the path of the XML files themselves) must be relative to the path of the HTML file which embeds the SWF file (and not relative to the SWF file - a common confusion).
If the folder path of the HTML differs from the product’s folder path (the folder in which the XML files and images or videos are located) then you must specify that path as value for the base attribute.
This is an example for 3D Banner FX (replace the product's name if you're using a different one):
- the index.html file is located at this address on your domain: http://www.yourdomain.com/index.html
- the swfobject.js file is located at this address: http://www.yourdomain.com/Banner/swfobject.js
- the product's files (XMLs, assets and images) are located in the Banner folder: http://www.yourdomain.com/Banner/
- the 3DBannerFX.swf file is located in the product's folder: http://www.yourdomain.com/Banner/3DBannerFX.swf
This is the embedding code you have to use:
<div id="Div3DBannerFX"></div> <script type="text/javascript" src="Banner/swfobject.js"></script> //specify the folder's name here <script type="text/javascript"> var flashvars = {}; var params = {}; params.base = "Banner/"; //specify the folder's name here params.scale = "noscale"; params.salign = "tl"; params.wmode = "transparent"; params.allowFullScreen = "true"; params.allowScriptAccess = "always"; swfobject.embedSWF("Banner/3DBannerFX.swf", "Div3DBannerFX", "600", "374", "9.0.0", false, flashvars, params); //specify the folder's name here </script>
You can also use absolute paths like in this example:
params.base = "http://www.yourdomain.com/Banner/";
In case you used a different folder name don't forget to replace in all locations the Banner name with the name of your folder.
Note: there are three different locations in the embedding code where you have to specify the product's folder name so make sure you update all of them.
Comments
Do you have a question?
you will get an answer in 24 hours, tops.
Stephanie Faison
Posted 7 years agoMy code is
<!— EOF- BANNER #2 display —> <div class=“flash”> <object width=“627” height=“352” classid=“clsid:D27CDB6E-AE6D-11cf-96B8-444553540000” codebase=“http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,24”> <param name=“movie” value=”<?php echo DIR_WS_TEMPLATE ?>flash/header_v8.swf?xmlUrl=<?php echo DIR_WS_TEMPLATE ?>flash/xml/&picUrl=<?php echo DIR_WS_TEMPLATE ?>flash/pic/” /> <param name=“quality” value=“high” /> <param name=“menu” value=“false” /> <param value=“http://www.macromedia.com/go/getflashplayer” name=“pluginurl”/> <!—[if !IE]> <—> <object type=“application/x-shockwave-flash” data=”<?php echo DIR_WS_TEMPLATE ?>flash/header_v8.swf?xmlUrl=<?php echo DIR_WS_TEMPLATE ?>flash/xml/&picUrl=<?php echo DIR_WS_TEMPLATE ?>flash/pic/” width=“627” height=“352” type=“application/x-shockwave-flash”> <param name=“quality” value=“high” /> <param name=“menu” value=“false” /> <param name=“pluginurl” value=“http://www.macromedia.com/go/getflashplayer” /> FAIL (the browser should render some flash content, not this). </object> <!—> <![endif]—>
Hi,
I had a look at the component you were trying to add to your page, and it doesn’t seem to be one of our components. Maybe I am mistaken, if this is so, please explain what component of ours you are trying to add to your page.
Another problem is with the filepath to your files, which is not correct. You have *http://www.executivetouch/catalog2/includes/templates/template_default/flash/
but this link should be like this:
http://www.executivetouchltd.com/catalog2/includes/templates/template_default/flash/
Plus, if you are using one of our components, you can use the direct embedding code
Stephanie Faison
Posted 7 years agoI am still having problems with my code which is located in a header.php file.
My files are located: – the index.html : http://www.executivetouchltd.com
- the swfobject.js file : http://www.executivetouch/catalog2/includes/templates/template_default/flash/
- the XML and images folders:
xml: http://www.executivetouch/catalog2/includes/templates/template_default/flash/xml/
images: http://www.executivetouch/catalog2/includes/templates/template_default/flash/pic
- the swf:
http://www.executivetouch/catalog2/includes/templates/template_default/flash/header_v8.swf
Brandon
Posted 7 years agoI am using dreamweaver to design my page. I already have the page flip component from you guys on a page that is working great. The problem is I am trying to use this 3D wall gallery on another page and the file names are all the same. When I insert the media into my line of code and copy and paste the script you guys have here it is using the settings.xml and images.xml folders for the page flip component already being used. I have the 3D wall in its own folder. How do I change it so it works?
Hi,
Please follow this tutorial, to add two components in two different pages.
triumph06
Posted 7 years agohi, i have a page call tv.html and that’s where i have the below code, I have the youtube video player in a folder call tv, but the tv2.html is outside this folder, the page is not showing the player, please what am i doing wrong
<script type=“text/javascript” src=“tv/swfobject.js”></script>
<script type=“text/javascript”>
var flashvars = {};
flashvars.folderPath = “tv/”;
var params = {};
params.scale = “noscale”;
params.salign = “tl”;
params.wmode = “transparent”;
params.allowScriptAccess = “always”;
var attributes = {};
swfobject.embedSWF(“tv/YouTubeVimeoPlayerFX.swf”, “DivYouTubeVimeoPlayerFX”, “600”, “300”, “9.0.0”, false, flashvars, params, attributes);
</script>
Hi,
Please provide a link to the webpage you are using the component to our support team.
David Thompson
Posted 7 years agoI have Cover Flow installed at ‘http://test2.exclusivelyweddings.co.uk/cover-flow/index_coverflow.html’ and it is working fine.
However when I copy the html file to ‘http://test2.exclusivelyweddings.co.uk/index_coverflow.html’ and modify the folder paths according to the instructions on your site, it doesn’t work.
Could you please take a look at this file and see what I am doing wrong with the paths?
<script type=“text/javascript” src=“cover-flow/swfobject.js”></script> <script type=“text/javascript”> var flashvars = {}; flashvars.folderpath = “cover-flow/”; var params = {}; params.scale = “noscale”; params.salign = “tl”; params.wmode = “transparent”; var attributes = {}; swfobject.embedSWF(“cover-flow/CoverFlowFX.swf”, “DivCoverFlowFX”, “1000”, “580”, “9.0.0”, false, flashvars, params, attributes);
One further question. I am using 48 images and the page load time is too slow, even though I have reduced the image quality as much as possible. Is there a way of speeding up the load time other than reducing the number of images?
Hi,
Right now the Cover Flow FX isn’t loading because it can’t load the first image in the images.xml
All the images in the XML must load in order for the component to work.
Unfortunately there's not much you can do about it, since the component has to load all the images and also render them in 3D, since CoverFlow is using a CPU heavy 3D engine. You can try to resize the images so they aren't larger than the actual viewsize on your site, and you could try to reduce the DPI, to 72, but other than that, not really.