Visit SlideShowPro.net  Community Forums
SlideShowPro Help Wiki
  

SlideShowPro Standalone

Embedding

The first step in using SlideShowPro Standalone is to embed it in a web page. We'll show you how here.

Add SWFObject

The first step is to add the SWFObject javascript library to your web page. This will embed the SWF in your web page, as well as detect Flash Player availability. Copy the following and paste it anywhere inside the <head> area of your document:

<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/swfobject/2.2/swfobject.js"></script>                                                                                     

Create DIV

Now we need a place for the SWF to appear. Anywhere in the <body> area, create a DIV by copying/pasting the code below:

<div id="flashcontent">
	This SlideShowPro photo gallery requires the Flash Player plugin and a web browser with JavaScript enabled.
</div>

Add Javascript

With SWFObject and our DIV in place, now we need the Javascript glue that instructs SWFObject what to do. Also in the <head> of your HTML document (after the SWFObject element added earlier), copy/paste the following:

<script type="text/javascript">
	var flashvars = {
	    loadParams: "false",
		initialURL: escape(document.location)
	}
	var params = { 
		bgcolor: "#000000",   
		allowfullscreen: "true"
	}                
	var attributes = {}
	swfobject.embedSWF("slideshowpro.swf", "flashcontent", "550", "400", "10.0.0", false, flashvars, params, attributes);  
</script>

Upload SWF

Now that the page code is done we need a place for the SWF to live. Connect to your web site using your favorite FTP client and upload the "slideshowpro.swf" file from the "Embed" folder in the Standalone ZIP archive to wherever you want to keep it (e.g., yourdomain.com/swf/slideshowpro.swf). You can use this single SWF for all the slideshows you create using SlideShowPro Standalone.

Edit Javascript

With slideshowpro.swf uploaded, we recommend changing the swf path in the Javascript code so it can be located easier. Edit the embedSWF method to an absolute path, like the following:

swfobject.embedSWF("http://yourdomain.com/swf/slideshowpro.swf", "flashcontent", "550", "400", "9.0.115.0", false, flashvars, params, attributes);  
</script>

Embed complete!

If you load your HTML document in a browser, you should see the SWF being embedded, and SlideShowPro Standalone should be displaying a "Slideshow data not found" error. Which means, you guessed it, it's time to assign some content. We'll do that next in Content.

Page last modified by tdominey on August 23, 2010, at 07:38 PM
© 2010 Dominey Design Inc. All Rights Reserved.
About | Merchandise | Contact | Privacy policy | Legal | Licensing