Visit SlideShowPro.net  Community Forums
SlideShowPro Help Wiki
  

SlideShowPro for Flash

Embed using Flash 8 and older code

The following instructions explain how to embed a SWF published by Macromedia Flash 8 or Flash MX 2004 using the player embed code in the HTML document Flash published alongside your SWF. Let's get started.

Step One: Upload content

Open an FTP connection to your web site and create a folder anywhere you like in your web site directory.

If you coded your own XML file and created your own images/videos (as demonstrated in the Quick Start walkthrough), upload to this folder the SWF file Flash published, your XML document, and the folders containing the images and/or videos your slideshow is loading.

If you are loading a Media RSS feed or content from SlideShowPro Director, you only need to upload the SWF.

In either case, you should not upload the FLA. It is not necessary for viewing online and should be kept on your local machine.

Step Two: Open new HTML document

With your slideshow content uploaded, open the HTML document you want to embed your SWF in. Be sure to use an ASCII / HTML text editor, like Notepad, Dreamweaver, TextWrangler, etc.

Step Three: Edit <body> with player embed code

Return to the HTML document Flash published and copy all of the code between <body> and </body>. Paste this wherever you like inside of your other HTML document.

Step Four: Edit SWF links

Now we need to edit the body code we just pasted so that it points to our SWF. Look for this in your player embed code:

<param name="movie" value="slideshow.swf" />

And a little bit after that, find this:

<embed src="slideshowpro.swf" 

Edit both of these with an absolute path to the SWF in the “slideshow” folder. For example:

<param name="movie" value="http://mydomain.com/slideshow/slideshow.swf" />
<embed src="http://mydomain.com/slideshow/slideshow.swf"
      quality="best" scale="noborder"
      bgcolor="#666666" width="550" height="400" name="slideshow"
      align="middle" allowScriptAccess="sameDomain"
      type="application/x-shockwave-flash"
      pluginspage="http://www.macromedia.com/go/getflashplayer" />

Step Five: Add base parameter

Note: If you are loading data from a Media RSS feed or SlideShowPro Director, this step is unnecessary and may be skipped. Continue to Step Six.

If your XML was coded with relative instead of absolute links (difference explained here) you need to make one additional modification. Add the following alongside the other existing <param> elements in your HTML document:

<param name="base" value="." />

Then add the following anywhere inside your existing <embed> element:

base="."

Your embed element should then look similar to this:

<embed base="." src="http://mydomain.com/slideshow/slideshow.swf" 
      quality="best" scale="noborder"
      bgcolor="#666666" width="550" height="400" name="slideshow"
      align="middle" allowScriptAccess="sameDomain"
      type="application/x-shockwave-flash"
      pluginspage="http://www.macromedia.com/go/getflashplayer" />

Adding a base parameter with a value of "." signifies to the Flash Player that all relative links should be relative to where the SWF is, not where the HTML document is (the default setting). Without this the SWF wouldn't be able to find "images.xml" and related content.

Step Six: Save and load

Save your HTML document and open it in your web browser. If all went well you should now see your slideshow in your own HTML document.

Troubleshooting

If however the slideshow doesn’t appear, go back over these instructions to ensure that you copied/modified everything correctly.

If your XML file was constructed using relative paths, and you’re linking to your SWF using a relative path from your HTML document, consider switching all your links to absolute. This includes the link to the SWF from your HTML document, the path to the XML file that SlideShowPro for Flash loads (assigned through XML File Path), as well as the image links in the XML file.

If you are trying to embed your SWF in an HTML document that’s under a different domain than where your XML file and images live, then the Flash Player may be denying you from loading the content because it didn’t receive permission to do so. How do you grant permission? See the "Can't load XML data from a different domain" troubleshooting document.

Page last modified by tdominey on April 22, 2009, at 06:35 AM
© 2010 Dominey Design Inc. All Rights Reserved.
About | Merchandise | Contact | Privacy policy | Legal | Licensing