bcSlideshow

a javascript slideshow for photographer and artist websites


calling bcSlideshow from your PhotoShelter gallery web page

This tutorial lists the steps you should follow to call bcSlideshow to show slideshows of your PhotoShelter galleries. This one’s pretty easy, too.

You should have a basic understanding of HTML and CSS markup.

First, follow the instructions to install a basic, single–slideshow version on your web page.

You can find those instructions here for your personal web site, and here for your PhotoShelter web pages.

In a pinch, you can make do with only one single–slideshow version of bcSlideshow. I have a basic version installed on my PhotoShelter home page; and I have a more configured version installed on custom page 2. I could show my gallery slideshows from my home page, but I prefer to use the version on page 2 because that configuration has a back button that will take the viewer back to my gallery if he or she sees something of interest.

On your PhotoShelter Gallery Display page, comment out or remove the gallery slideshow widget. Here’s how I’ve commented mine out:

<!-- <li>[[gallery_slideshow_link text="   or, view a flash slideshow"]]</li> -->

Add this short snippet of javascript to your web page. It’s a javascript function:

<script type="text/javascript">
 function callBcSlideshow() {
  var slideshowURL = 'http://bryancox.photoshelter.com/page2'; // this must be set to your page URL

  var gallery = document.location.toString();
  gallery = gallery.replace( /\/\s*$/, '' );
  gallery = gallery.substring( gallery.lastIndexOf('/') + 1 );
  slideshowURL = slideshowURL + '#' + gallery;
  window.location = slideshowURL;
 };
</script>

Be sure to change the slideshowURL string to point to YOUR slideshow page.

Finally, add a button or link to call the javascript function:

<input type="button" value="See a slideshow" onclick="javascript:callBcSlideshow();">

or

<a href="javascript:callBcSlideshow();" title="See a bcSlideshow of this gallery">See a slideshow</a>

In summary, here‘s all the code you need to display bcSlideshows of your galleries:

<script type="text/javascript">
 function callBcSlideshow() {
  var slideshowURL = 'http://bryancox.photoshelter.com/page2'; // this must be set to your page URL

  var gallery = document.location.toString();
  gallery = gallery.replace( /\/\s*$/, '' );
  gallery = gallery.substring( gallery.lastIndexOf('/') + 1 );
  slideshowURL = slideshowURL + '#' + gallery;
  window.location = slideshowURL;
 };
</script>

<a href="javascript:callBcSlideshow();" title="See a bcSlideshow of this gallery">See a slideshow</a>
Previous installation... Configurations...