Topic: Failing @ Multiple Gallery's on one page?!

I have a simple HTML site here that I am hoping to update to simple gallery pro and sv manager. Issue is I cant get it to work.

Here is a link to the site to get an idea:
http://applefordbuilding.ca/gallery.html

For each section I want to have a simple viewer gallery.

I have created multiple galleries, but the issue is they have to be in the root of the page which means I can only have one.

This is what I thought up:

I have tried naming them differently like:
simpleviewer1.swf - gallery1.xml
simpleviewer2.swf - gallery2.xml
then having all the images in the tumbs and images folder

Issue is the .swf is always looking for a "gallery.xml" file so this does not work. Is there a way to tell the simpleviewer.swf to look for gallery1.xml, gallery2.xml and so on? There must be a way around this...

Thanks,
Matt

Last edited by matt94gt (2011-05-06 19:29:41)

Re: Failing @ Multiple Gallery's on one page?!

Information on embedding 'Multiple Galleries on One HTML Page' can be found here: http://simpleviewer.net/simpleviewer/su … l#multiple
There is a downloadable example that you can take a look at.

Is there a way to tell the simpleviewer.swf to look for gallery1.xml, gallery2.xml and so on?

Yes. Use the galleryURL option as a flashvar, eg:

<!--START SIMPLEVIEWER EMBED.-->
<script type="text/javascript" src="svcore/js/simpleviewer.js"></script>
<script type="text/javascript">
var flashvars={}
flashvars.galleryURL="gallery1.xml";
simpleviewer.ready(function () {
simpleviewer.load("sv-container", "100%", "100%", "222222", true, flashvars);
});
</script>
<div id="sv-container"></div>
<!-- END SIMPLEVIEWER EMBED -->
Steven Speirs
SimpleViewer Support Team.

Re: Failing @ Multiple Gallery's on one page?!

I can never get the

<!--START SIMPLEVIEWER EMBED.-->
<script type="text/javascript" src="svcore/js/simpleviewer.js"></script>
<script type="text/javascript">
var flashvars={}
flashvars.galleryURL="gallery1.xml";
simpleviewer.ready(function () {
simpleviewer.load("sv-container", "100%", "100%", "222222", true, flashvars);
});
</script>
<div id="sv-container"></div>
<!-- END SIMPLEVIEWER EMBED -->

method to work.


I did this here:
http://voltagenewmedia.ca/appleford/gallery.html

Last edited by matt94gt (2011-05-06 20:36:27)

Re: Failing @ Multiple Gallery's on one page?!

NOTE:

<!--START SIMPLEVIEWER EMBED.-->
        <script type="text/javascript" src="../svcore/js/simpleviewer.js"></script>
       
        <script type="text/javascript">
        $(document).ready(function () {
            SV.simpleviewer.load('sv-container1', '800', '550', 'FFFFFF',true,{baseURL: 'gallery1/'});
        });
        </script>
        <div id="sv-container1"></div>
        <!-- END SIMPLEVIEWER EMBED -->   



Seems to be working!!! Thanks

Re: Failing @ Multiple Gallery's on one page?!

Hi,
I'm having the same problem. How do I change the sv-container name? Which files should I be renaming?
Thanks

Re: Failing @ Multiple Gallery's on one page?!

@Hortensie

Information on embedding 'Multiple Galleries on One HTML Page' can be found here: http://simpleviewer.net/simpleviewer/su … l#multiple
There is a downloadable example that you can take a look at.

Which files should I be renaming?

In order to have 2 different galleries, you will need two separate XML files (either named differently or in different locations).

The embedding code in your gallery's HTML index file might look something like this:

<script type="text/javascript" src="svcore/js/simpleviewer.js"></script>

<script type="text/javascript">
var flashvars1={};
flashvars1.galleryURL="gallery1.xml";
simpleviewer.ready(function () {
    simpleviewer.load('sv-container1', '800', '550', 'FFFFFF', true, flashvars1);
});
</script>
<div id="sv-container1"></div>

<script type="text/javascript">
var flashvars2={};
flashvars2.galleryURL="gallery2.xml";
simpleviewer.ready(function () {
    simpleviewer.load('sv-container2', '800', '550', 'FFFFFF', true, flashvars2);
});
</script>
<div id="sv-container2"></div>
Steven Speirs
SimpleViewer Support Team.

Re: Failing @ Multiple Gallery's on one page?!

Thank you for the quick response. It turns out I need to have the .xml files outside the gallery folder for it to work. Now the code is picking up both .xml files. Thanks very much for the help.