| If you have used the Slideshow module in Office Live you know it can be a problem, from the cannot display images to crashing the browser or site designer. This generator has a number of additional options, works best if you have the same sized images. 1. (opens in a new window). 2. Copy the following code into notepad: <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"> <xsl:output method="text" omit-xml-declaration="yes"/> <xsl:template match="/Footer"> <![CDATA[ ]]> </xsl:template> </xsl:stylesheet> 3. Copy the generator code into notepad after the <![CDATA[ tag: <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"> <xsl:output method="text" omit-xml-declaration="yes"/> <xsl:template match="/Footer"> <![CDATA[ <!-- configurable script --> <script language="JavaScript"> theimage = new Array(); theimage[0]=["http://solutionsforofficelive.com/images/addthis.jpg", "http://addthis.com", "Add This"]; theimage[1]=["http://solutionsforofficelive.com/images/enlarge.gif", "http://solutionsforofficelive.com", "Enlarge"]; playspeed=5000;i=0;
window.onload=function(){
preloadSlide(); SetSlide(0); PlaySlide(); } function SetSlide(num) { i=num%theimage.length; if(i<0)i=theimage.length-1; //switch the image document.images.imgslide.src=theimage[i][0]; document.getElementById('slidebox').innerHTML=theimage[i][2]; } function PlaySlide() { if (!window.playing) { PlayingSlide(i+1); if(document.slideshow.play){ document.slideshow.play.value=" Stop "; } } else { playing=clearTimeout(playing); if(document.slideshow.play){ document.slideshow.play.value=" Play "; } } if(document.images.imgPlay){ setTimeout('document.images.imgPlay.src="'+imgStop+'"',1); imgStop=document.images.imgPlay.src } }
function PlayingSlide(num) { playing=setTimeout('PlayingSlide(i+1);SetSlide(i+1);', playspeed); }
function preloadSlide() { for(k=0;k<theimage.length;k++) { theimage[k][0]=new Image().src=theimage[k][0]; } }
</script>
<!-- slide show HTML --> <form name="slideshow">
<table border="1" cellpadding="2" cellspacing="0"> <tr> <td align="center"> <a href="#" onmouseover="this.href=theimage[i][1];return false"> <script language="javascript"> document.write('<img name="imgslide" id="imgslide" src="'+theimage[0][0]+'" border="0">') </script> </a> </td> </tr> <tr> <td align="center"><div id="slidebox"></div></td> </tr> <tr> <td align="center"> <input type="button" value="I<<" onclick="SetSlide(0);" title="Jump to starting image"> <input type="button" value="<<" onclick="SetSlide(i-1);" title="Previous image"> <input type="button" name="play" value=" Play " onclick="PlaySlide();" title="Autoplay"> <input type="button" value=">>" onclick="SetSlide(i+1);" title="Jump to next image"> <input type="button" value=">>I" onclick="SetSlide(theimage.length-1);" title="Jump to ending image"> </td> </tr> </table> </form> <!-- end of slide show HTML --> ]]> </xsl:template> </xsl:stylesheet> 4. Copy the code from notepad and paste it into the Custom Footer module replacing everything else in the Cusotm Footer module. Note: If you do not have the Custom Footer module, you will need to activate Advanced Design Tools. Button Looks If you decide to use pictures for buttons, there are three main styles, but in each zip file there are several color choices, you only need to upload 1 set. |