window.thumbnails = {};
															thumbnails[1416197] = clik.newPhoto({"id":1416197,"src":"DSC_0057_edited-1-1JPG_thumb.jpg","galleries_id":"","server_id":18,"link":"#","width":130,"caption":"Berry Head, Brixham","height":86});
															thumbnails[1416199] = clik.newPhoto({"id":1416199,"src":"DSC_0064JPG_thumb.jpg","galleries_id":"","server_id":18,"link":"#","width":130,"caption":"View South from Berry Head, Brixham","height":86});
															thumbnails[1416243] = clik.newPhoto({"id":1416243,"src":"DSC_0013_edited-1JPG1_thumb.jpg","galleries_id":"","server_id":18,"link":"#","width":130,"caption":"Brixham Breakwater at Sunset","height":84});
															thumbnails[1416247] = clik.newPhoto({"id":1416247,"src":"DSC_0073_edited-1JPG_thumb.jpg","galleries_id":"","server_id":18,"link":"#","width":130,"caption":"Brixham Harbour at Dusk","height":86});
															thumbnails[5455666] = clik.newPhoto({"id":5455666,"src":"Safe20Haven1_thumb.jpg","galleries_id":201961,"server_id":18,"link":"photo_5455666.html","width":130,"caption":"Safe Haven","height":93});
															thumbnails[5554319] = clik.newPhoto({"id":5554319,"src":"Dragons_thumb.jpg","galleries_id":201955,"server_id":18,"link":"photo_5554319.html","width":130,"caption":"Dragons","height":86});
															thumbnails[5554324] = clik.newPhoto({"id":5554324,"src":"ESI_Jewellery_thumb.jpg","galleries_id":201963,"server_id":18,"link":"photo_5554324.html","width":130,"caption":"Semi precious stone jewellery","height":83});
															thumbnails[5554439] = clik.newPhoto({"id":5554439,"src":"Teddy_thumb.jpg","galleries_id":128901,"server_id":18,"link":"photo_5554439.html","width":130,"caption":"Brixham Teddy Bear","height":86});
															thumbnails[5592707] = clik.newPhoto({"id":5592707,"src":"Memories_Frontage_thumb.jpg","galleries_id":99710,"server_id":18,"link":"photo_5592707.html","width":130,"caption":"Memories, 14 The Quay, Brixham","height":86});
															thumbnails[3313791] = clik.newPhoto({"id":3313791,"src":"Smugglers Cove Jigsaw_thumb.jpg","galleries_id":201961,"server_id":18,"link":"photo_3313791.html","width":130,"caption":"Smuggler's Cove","height":92});
															thumbnails[5592710] = clik.newPhoto({"id":5592710,"src":"Memories_Frontage_2_thumb.jpg","galleries_id":99710,"server_id":18,"link":"photo_5592710.html","width":130,"caption":"Memories","height":86});
															thumbnails[5554322] = clik.newPhoto({"id":5554322,"src":"Ducks_thumb.jpg","galleries_id":201963,"server_id":18,"link":"photo_5554322.html","width":130,"caption":"Ducks","height":84});
															thumbnails[5554320] = clik.newPhoto({"id":5554320,"src":"Dolphins_thumb.jpg","galleries_id":201963,"server_id":18,"link":"photo_5554320.html","width":130,"caption":"Dolphins","height":86});
															thumbnails[1526126] = clik.newPhoto({"id":1526126,"src":"DSC_0055JPG_thumb.jpg","galleries_id":99709,"server_id":18,"link":"photo_1526126.html","width":130,"caption":"Golden Hind","height":86});
															thumbnails[5554424] = clik.newPhoto({"id":5554424,"src":"Recipe_Book_2_thumb.jpg","galleries_id":201963,"server_id":18,"link":"photo_5554424.html","width":130,"caption":"Favourite Devonshire Recipes Book","height":86});
															thumbnails[1526131] = clik.newPhoto({"id":1526131,"src":"DSC_0054JPG_thumb.jpg","galleries_id":99709,"server_id":18,"link":"photo_1526131.html","width":130,"caption":"Golden Hind","height":86});
															thumbnails[1932753] = clik.newPhoto({"id":1932753,"src":"DSC_0002_thumb.jpg","galleries_id":128901,"server_id":18,"link":"photo_1932753.html","width":130,"caption":"Brixham Pixie & Seagull Souvenirs","height":86});
															thumbnails[5554421] = clik.newPhoto({"id":5554421,"src":"Recipe_Book_1_thumb.jpg","galleries_id":201963,"server_id":18,"link":"photo_5554421.html","width":130,"caption":"West Country Teatime Recipes Book","height":86});
															thumbnails[5554372] = clik.newPhoto({"id":5554372,"src":"Maps_thumb.jpg","galleries_id":201963,"server_id":18,"link":"photo_5554372.html","width":130,"caption":"Old Maps (replicas)","height":86});
															thumbnails[1931303] = clik.newPhoto({"id":1931303,"src":"DSC_0003_edited-1-2_thumb.jpg","galleries_id":128901,"server_id":18,"link":"photo_1931303.html","width":130,"caption":"Traditional Seaside Souvenirs","height":96});
															thumbnails[5554420] = clik.newPhoto({"id":5554420,"src":"Pirates_thumb.jpg","galleries_id":201958,"server_id":18,"link":"photo_5554420.html","width":130,"caption":"Pirates","height":86});
															thumbnails[5554310] = clik.newPhoto({"id":5554310,"src":"Antique_Boat_thumb.jpg","galleries_id":99709,"server_id":18,"link":"photo_5554310.html","width":130,"caption":"Antique look fishing boat","height":86});
															thumbnails[1526147] = clik.newPhoto({"id":1526147,"src":"DSC_0052_edited-1_thumb.jpg","galleries_id":99710,"server_id":18,"link":"photo_1526147.html","width":130,"caption":"View from Memories of Brixham Inner Harbour","height":86});
															thumbnails[1917661] = clik.newPhoto({"id":1917661,"src":"DSC_0022-1_thumb.jpg","galleries_id":99709,"server_id":18,"link":"photo_1917661.html","width":130,"caption":"Cutty Sark","height":86});
															thumbnails[5554356] = clik.newPhoto({"id":5554356,"src":"Interior_thumb.jpg","galleries_id":99710,"server_id":18,"link":"photo_5554356.html","width":130,"caption":"Nautical display","height":69});
															thumbnails[5554365] = clik.newPhoto({"id":5554365,"src":"Interior_4_thumb.jpg","galleries_id":99710,"server_id":18,"link":"photo_5554365.html","width":130,"caption":"Glass Boat Display","height":85});
															thumbnails[1917666] = clik.newPhoto({"id":1917666,"src":"DSC_0024_thumb.jpg","galleries_id":99709,"server_id":18,"link":"photo_1917666.html","width":130,"caption":"HMS Victory","height":86});
															thumbnails[1917664] = clik.newPhoto({"id":1917664,"src":"DSC_0023_edited-1_thumb.jpg","galleries_id":99709,"server_id":18,"link":"photo_1917664.html","width":130,"caption":"The Mary Rose ","height":86});
															thumbnails[3599262] = clik.newPhoto({"id":3599262,"src":"DSC_0002_edited-1-1_thumb.jpg","galleries_id":113888,"server_id":18,"link":"photo_3599262.html","width":130,"caption":"Personalised Key Covers ","height":84});
															thumbnails[2123590] = clik.newPhoto({"id":2123590,"src":"DSC_0073_edited-1JPG_1_thumb.jpg","galleries_id":128901,"server_id":18,"link":"photo_2123590.html","width":130,"caption":"Local Photographs by Simon Hamling","height":86});
															thumbnails[5554361] = clik.newPhoto({"id":5554361,"src":"Interior_3_thumb.jpg","galleries_id":99710,"server_id":18,"link":"photo_5554361.html","width":130,"caption":"Ducks and Frogs!","height":86});
															thumbnails[1583398] = clik.newPhoto({"id":1583398,"src":"DSC_0058JPG_thumb.jpg","galleries_id":99709,"server_id":18,"link":"photo_1583398.html","width":130,"caption":"Large Model Trawler","height":86});
															thumbnails[5554317] = clik.newPhoto({"id":5554317,"src":"Smack_thumb.jpg","galleries_id":99709,"server_id":18,"link":"photo_5554317.html","width":130,"caption":"Fishing Smack","height":86});
															thumbnails[5554438] = clik.newPhoto({"id":5554438,"src":"Seagull_thumb.jpg","galleries_id":99709,"server_id":18,"link":"photo_5554438.html","width":130,"caption":"Seagulls","height":86});
															thumbnails[2123589] = clik.newPhoto({"id":2123589,"src":"DSC_0017_thumb.jpg","galleries_id":201958,"server_id":18,"link":"photo_2123589.html","width":130,"caption":"Pirates","height":86});

/***************************************************************************
* Create the array of Gallery objects                                      *
***************************************************************************/
var galleries = new Object();
				  						galleries[99710] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Memories of Brixham Inside and Out","link":"gallery_99710.html","maxRecords":0.0,"photoIDs":[5592707.0,5592710.0,1526147.0,5554356.0,5554365.0,5554361.0],"skipIndex":0,"section_code":"gallery","featured_images":"5592710,5592707,5554361","id":99710,"singleSection":false});				  						galleries[113888] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"History & Heraldry Sentiment & Personalised Gifts","link":"gallery_113888.html","maxRecords":0.0,"photoIDs":[3599262.0],"skipIndex":0,"section_code":"gallery","featured_images":3599262.0,"id":113888,"singleSection":false});				  						galleries[128901] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Souvenirs of Brixham and Devon","link":"gallery_128901.html","maxRecords":0.0,"photoIDs":[5554439.0,1932753.0,1931303.0,2123590.0],"skipIndex":0,"section_code":"gallery","featured_images":"5554439,2123590,1932753,1931303","id":128901,"singleSection":false});				  						galleries[99709] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Nautical Gifts","link":"gallery_99709.html","maxRecords":0.0,"photoIDs":[1526126.0,1526131.0,5554310.0,1917661.0,1917666.0,1917664.0,1583398.0,5554317.0,5554438.0],"skipIndex":0,"section_code":"gallery","featured_images":"5554317,5554310,1583398","id":99709,"singleSection":false});				  						galleries[201955] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Fantasy Figures","link":"gallery_201955.html","maxRecords":0.0,"photoIDs":[5554319.0],"skipIndex":0,"section_code":"gallery","featured_images":5554319.0,"id":201955,"singleSection":false});				  						galleries[201958] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Pirates","link":"gallery_201958.html","maxRecords":0.0,"photoIDs":[5554420.0,2123589.0],"skipIndex":0,"section_code":"gallery","featured_images":5554420.0,"id":201958,"singleSection":false});				  						galleries[201961] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Jigsaws","link":"gallery_201961.html","maxRecords":0.0,"photoIDs":[5455666.0,3313791.0],"skipIndex":0,"section_code":"gallery","featured_images":"5455666,3313791","id":201961,"singleSection":false});				  						galleries[201963] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"And Much, Much More.....","link":"gallery_201963.html","maxRecords":0.0,"photoIDs":[5554324.0,5554322.0,5554320.0,5554424.0,5554421.0,5554372.0],"skipIndex":0,"section_code":"gallery","featured_images":5554324.0,"id":201963,"singleSection":false});/***************************************************************************
* Create the array of image sets                                           *
***************************************************************************/
var imageSets = {};
imageSets[1] = '5592707,5592710';
imageSets[2] = '5592707,5554324,5554319,5592710,5554420,5554310,3599262,5554361,1583398,5554317';
imageSets[3] = '5592710,5592707,5554439,5554438,5554424,5554421,5554420,5554372,5554365,5554361,5554356,5554324,5554322,5554320,5554319,5554317,5554310,5455666,3599262,3313791,2123590,2123589,1932753,1931303,1917666,1917664,1917661,1583398,1526147,1526131,1526126,1416247,1416243,1416199,1416197';
 /***************************************************************************
* Get a server path given an ID                                            *
***************************************************************************/
function getServerPath(server_id) {
	var val = -1;
		switch (server_id) {
		case 51:
		val = 'http://www12.clikpic.com/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 0:
		val = 'http://www.clikpic.com/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 1:
		val = 'http://www1.clikpic.com/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 2:
		val = 'http://admin.clikpic.com/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 24:
		val = 'http://tpc15/clikpic/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 4:
		val = 'http://clikchurch.clikpic.com/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 5:
		val = 'http://www2.clikpic.com/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 22:
		val = 'http://tpc5/clikpic/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 23:
		val = 'http://tpc10/clikpic/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 25:
		val = 'http://tpc16/clikpic/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 26:
		val = 'http://tpc20/clikpic/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 40:
		val = 'http://www11.clikpic.com/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 42:
		val = 'db2.clikpic.com/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 15:
		val = 'http://www3.clikpic.com/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 18:
		val = 'http://www4.clikpic.com/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 19:
		val = 'http://www5.clikpic.com/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 31:
		val = 'http://www7.clikpic.com/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 32:
		val = 'http://www8.clikpic.com/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 34:
		val = 'http://www9.clikpic.com/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 35:
		val = 'http://admin3.clikpic.com/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 37:
		val = 'http://admin4.clikpic.com/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 38:
		val = 'http://admin5.clikpic.com/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 39:
		val = 'http://www10.clikpic.com/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 53:
		val = 'http://images.clikpic.com/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 52:
		val = 'http://tpc22/clikpic/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 21:
		val = 'http://www6.clikpic.com/Simon_Judy/images';
		break;
	}
		switch (server_id) {
		case 50:
		val = '[cliktext value=article.servers_id type=servers_id]/Simon_Judy/images';
		break;
	}
		return val;
}

/***************************************************************************
* img = reference to image object in which to show image                   *
***************************************************************************/
function showHomeImage(img) {
	imageID = randomListVal('');
	if (!basic) {
		img.src = photos[imageID].src;
		img.width = photos[imageID].width;
		img.height = photos[imageID].height;
		img.parentNode.title = img.alt = photos[imageID].caption;
	} else {
		newImage = new Image(photos[imageID].width,photos[imageID].height);
		newImage.src = photos[imageID].src;
		document.images[img.name] = newImage;
		
	}
}

function getHomeImageLink(imageID) {
  	var href='', photo = (backgrounds || photos || {})[imageID];
	if(photo){
		if (photo && photo.galleries_id != '') {
  			href = photo.fnGalleryLink();
  		}
  		  		else {
  				href += 'gallery.html';
  	  		}
	}
    return href;
}

/***************************************************************************
* Show a random image on home page from featured images                    *
***************************************************************************/
function showHomeImageInline(el, image_sets_id, href) {
	
	var css = {}, imageID,
	    imageSetsId = 1;
	if(image_sets_id){
		imageSetsId = image_sets_id;
	}
	imageID = randomListVal(imageSets[imageSetsId]);
	if (href == null && 'gallery' != '') {
					href = getHomeImageLink(imageID);
	}
	
	updateImage({nextPhoto: backgrounds[imageID], img:el.find('img')[0],
                $photo:el, $title:$('#homeimageTitleContainer'), $detail:$('#homeimageDetailsContainer'),                speed:0, href:href, css:css, onAfter: function(){                  this.closest('.contentsection').doManualAlign({				    inner: 'img',				    crop: 'a'				  });                }              });
}

/***************************************************************************
* Set 'img' to be a new image given its photo() object                     *
***************************************************************************/
function updateImage (options) {
	var defaults = {nextPhoto:'',field:'',img:'',$photo:'',$title:'',$detail:'',$detailContainer:'',
                    updateDocumentTitle:false,speed:0,href:false,css:false,updateHash:false,onAfter:null,onBefore:null},
		op = $.extend({},defaults,options),
		html = '', temp = '',
		photoId = op.nextPhoto.id,
		photoCaption = ''+op.nextPhoto.caption,
		photoSrc = op.nextPhoto.src;
	
	if (op.updateHash && clik.getIDInUrl(location.href,'photo') != op.nextPhoto.id) {
		clik.changeHash('photos_id=' + op.nextPhoto.id, true);
	}
		
	    if (op.$title.length > 0) {
  		op.$title.fadeGalleryDetails(photoCaption, op.speed);
    }
        if (op.updateDocumentTitle) {
						  document.title = 'Memories - a harbourside gift shop in Brixham: ' + photoCaption;
			    }
        if (op.$detail.length > 0) {
      	temp = op.nextPhoto.fnGetImageDetails();
	    op.$detail.fadeGalleryDetails(temp, op.speed, function(){
			if (typeof(backgrounds) != 'undefined' && op.nextPhoto == backgrounds[op.nextPhoto.id]) {
				toggleAddToCartConfirm(backgrounds, op.$detail);
			} else if (typeof(photos) != 'undefined' && op.nextPhoto == photos[op.nextPhoto.id]) {
				toggleAddToCartConfirm(photos, op.$detail);
			}
			$('body').trigger('clikUpdate.popup');
	    });
    }
        $(op.$detailContainer).find('.replaceable[class*=replaceable_photo-]').each(function(){
    	var field = clik.getPrefixedClass(this.className, 'replaceable_photo-');
    	if (field in op.nextPhoto) {
    		$(this).fadeGalleryDetails(op.nextPhoto[field], op.speed);
    	}
    }).end().find('.replaceable.photoPayment').fadeGalleryDetails(op.nextPhoto.fnGetPaymentInfo(), op.speed, function(){
		if (typeof(backgrounds) != 'undefined' && op.nextPhoto == backgrounds[op.nextPhoto.id]) {
			toggleAddToCartConfirm(backgrounds, op.$detailContainer);
		} else if (typeof(photos) != 'undefined' && op.nextPhoto == photos[op.nextPhoto.id]) {
			toggleAddToCartConfirm(photos, op.$detailContainer);
		}
		$('body').trigger('clikUpdate.popup');
	});
		if (op.$photo.length > 0) {
		html = $('<img/>',{
			'class': 'mainphoto photo',
			src: photoSrc,
			id: 'mainPic',
			name: 'mainPic',
			width: op.nextPhoto.width,
			height: op.nextPhoto.height,
			alt: photoCaption,
			css: op.css || {}
		});
		if (op.href) {
			if (op.href.match(/<a/)) {
				html = $(op.href).append(html);
			} else {
				html = $('<a/>', {
					href: op.href,
					title: photoCaption
				}).append(html);
			}
		} else {
			html = $('<a/>', {
				title: photoCaption
			}).append(html);
		}
		if (op.speed == 0) {			op.$photo.html(html);			if (op.onBefore) {			  	op.onBefore.apply(op.$photo);			}			if (op.onAfter) {			  	op.onAfter.apply(op.$photo);			}		} else {			op.$photo.stop(true,true).fadeReplaceWith(html,op.speed,'',function(){  				if (op.onAfter) {				  	op.onAfter.apply(this);				}				clik.doColumnResize(false, $(this).add(op.$detail).add(op.$title));			}, op.onBefore);
		}	}
    if (op.field) {
		op.field.value = photoId;
	} else {
		op.$photo.data('image_id', photoId);
    }
        if (!op.speed) {
      	clik.doColumnResize(false, op.$photo.add(op.$detail).add(op.$title));
    }
        
    return html;
	}

/***************************************************************************
* Toggle add to cart confirmation element and set up the click event for   *
* the 'Add to cart' button.                                                *
***************************************************************************/
function toggleAddToCartConfirm(array, root){
	if (typeof(array) !== 'object' || array === null) {
	  	array = photos;
	}
	if (!$(root).length) {		root = $('body');	}	if($('#paymentConfirm', root).length > 0){
		$('#paymentConfirm', root).hide();
		$('#paymentAddButton', root)
		.unbind()
		.click(function(){
						form = $('#paymentForm', root)[0];
			option_id = 0;
			if(form.item_option.value){
				option_id = form.item_option.value;
			}
			if(addItemToBasket(form.item_number.value,array,form.site.value,parseInt(form.quantity.value, 10),option_id)){
				if($.browser.msie){$('#paymentConfirm', root).text('Item added to cart').show();}
				else{
					$('#paymentConfirm', root).text('Item added to cart').fadeIn();
					dspOrderDetails(form.site.value);
				}
			}
			else{
				$('#paymentConfirm', root).text('Item not added - check cookies are enabled in your browser.').fadeIn();
			}
		});
	}
}

/***************************************************************************
* Get payment info for image - add as 'method' to photo object             *
***************************************************************************/
clik.photo.fnGetImageDetails = function(){
	var temp = '';
	if (this.description != '') {
		temp +=  '<div id="imageDescription">' + this.description + '</div>';
	}
		if (this.photo_ref != '') {
		temp += '<div class="imageinfo" id="imageRef"><strong>Ref: </strong>' + this.photo_ref + '</div>';
	}
		if (this.takendate != '') {
		
		temp += '<div class="imageinfo" id="imageDate"><strong>Date: </strong>' + this.takendate + '</div>';
	}
	
	if (this.location != '') {
		
		temp += '<div class="imageinfo" id="imageLocation"><strong>Location: </strong>' +  this.location + '</div>';
	}
	
	if (this.photographer != '') {
		
		temp += '<div class="imageinfo" id="imagePhotographer"><strong>Photographer: </strong>' + this.photographer + '</div>';
	}
				
				if (temp != '') {
		temp += '<div class="spacer"></div>';
	}
	return temp;
};

/***************************************************************************
* Get payment info for image - add as 'method' to photo object             *
***************************************************************************/
clik.photo.fnGetPaymentInfo = function(){
	var temp = '';
	if (this.item_price !== '') {
				temp += '<p>Order this print:</p>';
				temp += '<div class="imageinfo" id="imagePrice"><strong>' + this.purchase_instruction + '</strong> ' + (this.item_price).toFixed(2) + '</div>';
		var item_name  = this.purchase_instruction;
		var amount = (this.item_price).toFixed(2);
		var item_option  = 0;
	}
		else {
		
	}
	if (this.item_price !== '') {
			temp += '<div class="clearing">&nbsp;</div>';
	}
	return temp;};

/***************************************************************************
* Pick a photo at random from the featured images of a gallery.            *
* Gallery_id = id of gallery to choose,                                    *
* img = reference to html image in                                         *
* which to show image                                                      *
***************************************************************************/
function showGalleryImage(gallery_id, img, updateLink) {
	
	if(img){
		if (location.hash.match('galleries_id=' + gallery_id) && (imageID = location.hash.match('.*photos_id=(.+)$'))) {
		  	imageID = imageID[1];
		} else {
		  	imageID = randomListVal(galleries[gallery_id].featured_images);
		}
		
		if (imageID != 0) {
			img.src = thumbnails[imageID].src;
			img.width = thumbnails[imageID].width;
			img.height = thumbnails[imageID].height;
			img.alt = galleries[gallery_id].title;
			if (updateLink) {
				$(img).parent().attr({					title: galleries[gallery_id].title				}).filter(function(){return this.href;}).attr({					href: thumbnails[imageID].fnGalleryLink(gallery_id)				});
			}
		}
	}
}

/***************************************************************************
* If we have dynamic HTML, replace the galleries link with a list that     *
* doesn't include thecurrent gallery                                       *
***************************************************************************/
function showGalleries(gallery_id) {
		
	
	if (!basic) {
		temp = '';
		for (i = 0; i < galleries.length; i++) {
						
			
			if (galleries[i].id != gallery_id) {
								
				if (temp != '') {
					temp += ' | ';
				}
								temp += '<a href="' + galleries[i].section_code + '_' + galleries[i].id + '.html">' + galleries[i].title + '</a>';
							}
		}
		document.all.galleryLinks.innerHTML = 'Other galleries: ' + temp;
	}
}

			

