Adding an Image Slide Show

Topics: Developer Forum, User Forum
Aug 6, 2008 at 2:11 AM
I have some java script code that I would like to place an image slide show in the Side Bar portion of the web site under the vertical navigation pane.  Is there a way to do this, and if so, where would I need to place the js/html code in order for it to show up and work properly?

Also is this an easy control that can be created and placed.  If so, can someone tell me how to do this, or help me create it as I dont know code and wouldnt know the first thing about creating an easy control, thanks.
Oct 5, 2008 at 6:07 PM
hey,

i've just added a flash gallery on my site! it is the simple flash gallery. it use a modified rss to load the images. just look at www.nissan-team-vogtland.de, on the bottom of the content you find a link called "flash galerie".

if you need more information about this, reply me ;)

greets Enno
Oct 7, 2008 at 2:39 AM
Hey Enno,
                  I got SimpleViewer working as a Easy Control, however I would like to see how you got it working in the Gallery Section Control.

Thanks,
THEFAV
Oct 9, 2008 at 2:09 PM
Edited Oct 9, 2008 at 2:13 PM
Hey THEFAV,

that is really easy! i just cloned the silverlight element in the gallery section panel and added in the code :

Gallery.ascx

<asp:View runat="server" ID="vwFlashGallery">
                <div id="<%=ClientID%>FlashGalleryHost" >
                    <div id="flashcontent">SimpleViewer requires JavaScript and the Flash Player. <a href="http://www.macromedia.com/go/getflashplayer/">Get Flash.</a></div>
                    <script type="text/javascript">
                        var fo = new SWFObject("flashgallery/viewer.swf", "simpleviewer", "100%", "680", "8", "#ffffff");

                        // SIMPLEVIEWER CONFIGURATION OPTIONS
                        // To use an option, uncomment it by removing the "//" at the start of the line
                        // For a description of config options, go to:
                        // http://www.airtightinteractive.com/simpleviewer/options.html
       
                        fo.addVariable("xmlDataPath", " <%=getFlashGalleryXml()%>");
                        //fo.addVariable("firstImageIndex", "5");   
                        //fo.addVariable("langOpenImage", "Open Image in New Window");
                        //fo.addVariable("langAbout", "About");   
                        //fo.addVariable("preloaderColor", "0xFFFFFF");
       
                        fo.write("flashcontent");   
                    </script>
                </div>
                <br />
                <asp:LinkButton runat="server" ID="btnShowHtmlVersion2" Text="<%$Resources:StringsRes, ctl_Gallery_HTMLVersion %>" OnClick="btnShowHtmlVersion_Click"></asp:LinkButton>
</asp:View>

Gallery.ascx.cs


if (mvHtmlSilverlight.GetActiveView() == vwFlashGallery)
   { Page.ClientScript.RegisterClientScriptInclude("SimpleViewerGallery", ResolveUrl("~/FlashGallery/swfobject.js")); }


In the folder "FlashGallery" is the js and swf file from simpleviewer.

so on, i create a clone of sectionrss.ashx and trim this to get a xml-code to fill the flashgallery!

here the function to call the xml creator:
protected string getFlashGalleryXml()
    { return ResolveUrl("~/FlashGallery.ashx?psid=" + Sidebar.CreatePageSectionKey(Section.SectionId, getPageId())); }


i think, it is all, that i added.... ;o)

just try it, but i take no guarantee or warranty ;o)

greets
Enno
Oct 9, 2008 at 7:02 PM
Hey Enno,
                 I have everything working except for the FlashGallery.ashx is not getting the XML data could you expand a bit on what this file should look like?


Thnaks THEFAV
Oct 27, 2008 at 3:16 PM
Has anyone resolved the problem of not getting the XML data?
Jan 14, 2011 at 11:23 AM

I need to make something close to this but have had no luck up to now.On the home page,i want to place image slideshow using javascript.It works fine on html but misbehaves on FCKeditor.Please guide me.i have ran out of ideas.