window.thumbnails = {};
															thumbnails[2132824] = clik.newPhoto({"id":2132824,"src":"Anthony_Cini_Sports_Malta_Jan08_thumb.jpg","galleries_id":143003,"server_id":32,"link":"photo_2132824.html","width":130,"caption":"","height":127});
															thumbnails[2132825] = clik.newPhoto({"id":2132825,"src":"Anthony_Cini_Pictorial_Apr08_Malta_thumb.jpg","galleries_id":141695,"server_id":32,"link":"photo_2132825.html","width":130,"caption":"","height":90});
															thumbnails[2132901] = clik.newPhoto({"id":2132901,"src":"Dorianne_thumb.jpg","galleries_id":141871,"server_id":32,"link":"photo_2132901.html","width":130,"caption":"","height":191});
															thumbnails[2135583] = clik.newPhoto({"id":2135583,"src":"Adreianna_thumb.jpg","galleries_id":141871,"server_id":32,"link":"photo_2135583.html","width":130,"caption":"","height":223});
															thumbnails[2135586] = clik.newPhoto({"id":2135586,"src":"farfettblu_thumb.jpg","galleries_id":141695,"server_id":32,"link":"photo_2135586.html","width":130,"caption":"Common Blue","height":162});
															thumbnails[2135588] = clik.newPhoto({"id":2135588,"src":"glassrose_thumb.jpg","galleries_id":141695,"server_id":32,"link":"photo_2135588.html","width":130,"caption":"","height":187});
															thumbnails[2137529] = clik.newPhoto({"id":2137529,"src":"threetoms_thumb.jpg","galleries_id":141695,"server_id":32,"link":"photo_2137529.html","width":130,"caption":"Three","height":187});
															thumbnails[2145696] = clik.newPhoto({"id":2145696,"src":"ReachingHigh_thumb.jpg","galleries_id":143003,"server_id":32,"link":"photo_2145696.html","width":130,"caption":"Reaching High","height":182});
															thumbnails[2156294] = clik.newPhoto({"id":2156294,"src":"gotit_thumb.jpg","galleries_id":143003,"server_id":32,"link":"photo_2156294.html","width":130,"caption":"","height":184});
															thumbnails[2156300] = clik.newPhoto({"id":2156300,"src":"Bikemanwbrd_thumb.jpg","galleries_id":143003,"server_id":32,"link":"photo_2156300.html","width":130,"caption":"No Pain No Gain","height":90});
															thumbnails[2156325] = clik.newPhoto({"id":2156325,"src":"Ana01_thumb.jpg","galleries_id":141871,"server_id":32,"link":"photo_2156325.html","width":130,"caption":"Post wedding booking deposit","height":198});
															thumbnails[2156334] = clik.newPhoto({"id":2156334,"src":"Angie02_thumb.jpg","galleries_id":141871,"server_id":32,"link":"photo_2156334.html","width":130,"caption":"","height":202});
															thumbnails[2184196] = clik.newPhoto({"id":2184196,"src":"Anton_Cini_Commercial_May08_Malta_thumb.jpg","galleries_id":141871,"server_id":32,"link":"photo_2184196.html","width":130,"caption":"Enjoying Life","height":98});
															thumbnails[2184201] = clik.newPhoto({"id":2184201,"src":"Anthony_Cini_Pictorial_Malta_May08_thumb.jpg","galleries_id":141695,"server_id":32,"link":"photo_2184201.html","width":130,"caption":"","height":98});
															thumbnails[2625867] = clik.newPhoto({"id":2625867,"src":"Anthony_Cini_sports_Malta_July08_thumb.jpg","galleries_id":143003,"server_id":32,"link":"photo_2625867.html","width":130,"caption":"Right Hook","height":101});
															thumbnails[2627341] = clik.newPhoto({"id":2627341,"src":"Lilli1_thumb.jpg","galleries_id":141871,"server_id":32,"link":"photo_2627341.html","width":130,"caption":"","height":145});
															thumbnails[2627624] = clik.newPhoto({"id":2627624,"src":"Jun08_thumb.jpg","galleries_id":141871,"server_id":32,"link":"photo_2627624.html","width":130,"caption":"","height":90});
															thumbnails[2723470] = clik.newPhoto({"id":2723470,"src":"Anton_Cini_Sports_Malta_Aug08_thumb.jpg","galleries_id":143003,"server_id":32,"link":"photo_2723470.html","width":130,"caption":"Dione","height":90});
															thumbnails[4332602] = clik.newPhoto({"id":4332602,"src":"Chant01_thumb.jpg","galleries_id":141871,"server_id":32,"link":"photo_4332602.html","width":130,"caption":"","height":173});
															thumbnails[4332708] = clik.newPhoto({"id":4332708,"src":"ChurchSunrise_thumb.jpg","galleries_id":141695,"server_id":32,"link":"photo_4332708.html","width":130,"caption":"","height":90});
															thumbnails[4332712] = clik.newPhoto({"id":4332712,"src":"Anthony_Cini_no3_thumb.jpg","galleries_id":141695,"server_id":32,"link":"photo_4332712.html","width":130,"caption":"","height":101});
															thumbnails[5244924] = clik.newPhoto({"id":5244924,"src":"Anton_Cini_01_thumb.jpg","galleries_id":295569,"server_id":32,"link":"photo_5244924.html","width":130,"caption":"Kate","height":188});
															thumbnails[5244930] = clik.newPhoto({"id":5244930,"src":"Anton_Cini_02_thumb.jpg","galleries_id":295569,"server_id":32,"link":"photo_5244930.html","width":130,"caption":"Corinna","height":182});
															thumbnails[5374415] = clik.newPhoto({"id":5374415,"src":"Anton_Cini_03_thumb.jpg","galleries_id":295569,"server_id":32,"link":"photo_5374415.html","width":130,"caption":"","height":181});
															thumbnails[5374420] = clik.newPhoto({"id":5374420,"src":"Anton_Cini_04_339404A4-1D09-001F-9900DF20BA3C9200_thumb.jpg","galleries_id":295569,"server_id":32,"link":"photo_5374420.html","width":130,"caption":"","height":90});
															thumbnails[5374422] = clik.newPhoto({"id":5374422,"src":"Anton_Cini_05_thumb.jpg","galleries_id":295569,"server_id":32,"link":"photo_5374422.html","width":130,"caption":"","height":92});
															thumbnails[5374423] = clik.newPhoto({"id":5374423,"src":"Anton_Cini_06_thumb.jpg","galleries_id":295569,"server_id":32,"link":"photo_5374423.html","width":130,"caption":"","height":102});
															thumbnails[6666061] = clik.newPhoto({"id":6666061,"src":"Celine01web_thumb.jpg","galleries_id":364365,"server_id":32,"link":"photo_6666061.html","width":130,"caption":"","height":161});
															thumbnails[6666102] = clik.newPhoto({"id":6666102,"src":"jenniferweb01_thumb.jpg","galleries_id":364365,"server_id":32,"link":"photo_6666102.html","width":130,"caption":"","height":92});
															thumbnails[6666141] = clik.newPhoto({"id":6666141,"src":"Ian_thumb.jpg","galleries_id":364365,"server_id":32,"link":"photo_6666141.html","width":130,"caption":"","height":90});
															thumbnails[6726350] = clik.newPhoto({"id":6726350,"src":"jenniferweb_thumb.jpg","galleries_id":364365,"server_id":32,"link":"photo_6726350.html","width":130,"caption":"","height":91});
															thumbnails[6896982] = clik.newPhoto({"id":6896982,"src":"Amanda01_thumb.jpg","galleries_id":364365,"server_id":32,"link":"photo_6896982.html","width":130,"caption":"","height":186});
															thumbnails[6896984] = clik.newPhoto({"id":6896984,"src":"Chantell01_thumb.jpg","galleries_id":364365,"server_id":32,"link":"photo_6896984.html","width":130,"caption":"","height":177});
															thumbnails[7656723] = clik.newPhoto({"id":7656723,"src":"whereto_thumb.jpg","galleries_id":141695,"server_id":32,"link":"photo_7656723.html","width":130,"caption":"Locked","height":102});
															thumbnails[7656744] = clik.newPhoto({"id":7656744,"src":"Marsa140803_049ps_thumb.jpg","galleries_id":141695,"server_id":32,"link":"photo_7656744.html","width":130,"caption":"High In The Sky","height":173});
															thumbnails[7656747] = clik.newPhoto({"id":7656747,"src":"faceOne_thumb.jpg","galleries_id":141871,"server_id":32,"link":"photo_7656747.html","width":130,"caption":"Melissa","height":65});
															thumbnails[7989999] = clik.newPhoto({"id":7989999,"src":"KJ01_thumb.jpg","galleries_id":429594,"server_id":32,"link":"photo_7989999.html","width":130,"caption":"Karyn & Jason","height":87});
															thumbnails[8009324] = clik.newPhoto({"id":8009324,"src":"IMG_1591adj_thumb.jpg","galleries_id":429594,"server_id":32,"link":"photo_8009324.html","width":130,"caption":"Karyn & Jason","height":92});
															thumbnails[8781833] = clik.newPhoto({"id":8781833,"src":"Whiteup_thumb.jpg","galleries_id":141695,"server_id":32,"link":"photo_8781833.html","width":130,"caption":"White Cup","height":79});
															thumbnails[8855054] = clik.newPhoto({"id":8855054,"src":"MdinaLion_WebImage_thumb.jpg","galleries_id":141695,"server_id":32,"link":"photo_8855054.html","width":130,"caption":"Mdina","height":110});

/***************************************************************************
* Create the array of Gallery objects                                      *
***************************************************************************/
var galleries = new Object();
				  						galleries[141871] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Fashion & Beauty","link":"gallery_141871.html","maxRecords":0.0,"photoIDs":[2132901.0,2135583.0,2156325.0,2156334.0,2184196.0,2627341.0,2627624.0,4332602.0,7656747.0],"skipIndex":0,"section_code":"gallery","featured_images":2627341.0,"id":141871,"singleSection":false});				  						galleries[295569] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Flickristi Selmun Meeting","link":"gallery_295569.html","maxRecords":0.0,"photoIDs":[5244924.0,5244930.0,5374415.0,5374420.0,5374422.0,5374423.0],"skipIndex":0,"section_code":"gallery","featured_images":"5374423,5374422,5374420","id":295569,"singleSection":false});				  						galleries[429594] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Karyn & Jason","link":"gallery_429594.html","maxRecords":0.0,"photoIDs":[7989999.0,8009324.0],"skipIndex":0,"section_code":"gallery","featured_images":"8009324,7989999","id":429594,"singleSection":false});				  						galleries[141695] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Gallery 1","link":"gallery_141695.html","maxRecords":0.0,"photoIDs":[2132825.0,2135586.0,2135588.0,2137529.0,2184201.0,4332708.0,4332712.0,7656723.0,7656744.0,8781833.0,8855054.0],"skipIndex":0,"section_code":"gallery","featured_images":"8781833,7656723","id":141695,"singleSection":false});				  						galleries[364365] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Maltese Photo Models","link":"gallery_364365.html","maxRecords":0.0,"photoIDs":[6666061.0,6666102.0,6666141.0,6726350.0,6896982.0,6896984.0],"skipIndex":0,"section_code":"gallery","featured_images":"6896984,6896982,6726350,6666141,6666102,6666061","id":364365,"singleSection":false});				  						galleries[143003] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Sports","link":"gallery_143003.html","maxRecords":0.0,"photoIDs":[2132824.0,2145696.0,2156294.0,2156300.0,2625867.0,2723470.0],"skipIndex":0,"section_code":"gallery","featured_images":"2723470,2625867,2156300,2156294,2145696,2132824","id":143003,"singleSection":false});/***************************************************************************
* Create the array of image sets                                           *
***************************************************************************/
var imageSets = {};
imageSets[1] = '8855054,8781833,7656723,5374423,5374422,5374420,5244930,5244924,4332712,2723470,2627341,2625867,2156300,2132825';
imageSets[2] = '8781833,7656723,5374423,5374422,5374420,2627341';
imageSets[3] = '6666141,6666102,6666061,5374423,5374422,5374420';
 /***************************************************************************
* Get a server path given an ID                                            *
***************************************************************************/
function getServerPath(server_id) {
	var val = -1;
		switch (server_id) {
		case 51:
		val = 'http://www12.clikpic.com/antoncini/images';
		break;
	}
		switch (server_id) {
		case 0:
		val = 'http://www.clikpic.com/antoncini/images';
		break;
	}
		switch (server_id) {
		case 1:
		val = 'http://www1.clikpic.com/antoncini/images';
		break;
	}
		switch (server_id) {
		case 2:
		val = 'http://admin.clikpic.com/antoncini/images';
		break;
	}
		switch (server_id) {
		case 24:
		val = 'http://tpc15/clikpic/antoncini/images';
		break;
	}
		switch (server_id) {
		case 4:
		val = 'http://clikchurch.clikpic.com/antoncini/images';
		break;
	}
		switch (server_id) {
		case 5:
		val = 'http://www2.clikpic.com/antoncini/images';
		break;
	}
		switch (server_id) {
		case 22:
		val = 'http://tpc5/clikpic/antoncini/images';
		break;
	}
		switch (server_id) {
		case 23:
		val = 'http://tpc10/clikpic/antoncini/images';
		break;
	}
		switch (server_id) {
		case 25:
		val = 'http://tpc16/clikpic/antoncini/images';
		break;
	}
		switch (server_id) {
		case 26:
		val = 'http://tpc20/clikpic/antoncini/images';
		break;
	}
		switch (server_id) {
		case 40:
		val = 'http://www11.clikpic.com/antoncini/images';
		break;
	}
		switch (server_id) {
		case 42:
		val = 'db2.clikpic.com/antoncini/images';
		break;
	}
		switch (server_id) {
		case 15:
		val = 'http://www3.clikpic.com/antoncini/images';
		break;
	}
		switch (server_id) {
		case 18:
		val = 'http://www4.clikpic.com/antoncini/images';
		break;
	}
		switch (server_id) {
		case 19:
		val = 'http://www5.clikpic.com/antoncini/images';
		break;
	}
		switch (server_id) {
		case 31:
		val = 'http://www7.clikpic.com/antoncini/images';
		break;
	}
		switch (server_id) {
		case 32:
		val = 'http://www8.clikpic.com/antoncini/images';
		break;
	}
		switch (server_id) {
		case 34:
		val = 'http://www9.clikpic.com/antoncini/images';
		break;
	}
		switch (server_id) {
		case 35:
		val = 'http://admin3.clikpic.com/antoncini/images';
		break;
	}
		switch (server_id) {
		case 37:
		val = 'http://admin4.clikpic.com/antoncini/images';
		break;
	}
		switch (server_id) {
		case 38:
		val = 'http://admin5.clikpic.com/antoncini/images';
		break;
	}
		switch (server_id) {
		case 39:
		val = 'http://www10.clikpic.com/antoncini/images';
		break;
	}
		switch (server_id) {
		case 53:
		val = 'http://images.clikpic.com/antoncini/images';
		break;
	}
		switch (server_id) {
		case 52:
		val = 'http://tpc22/clikpic/antoncini/images';
		break;
	}
		switch (server_id) {
		case 21:
		val = 'http://www6.clikpic.com/antoncini/images';
		break;
	}
		switch (server_id) {
		case 50:
		val = '[cliktext value=article.servers_id type=servers_id]/antoncini/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 = 'Anton Cini: ' + 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>';
	}
				
	temp += this.fnGetPaymentInfo();
				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>Buy now using PayPal:</p>';
				temp += '<div class="imageinfo" id="imagePrice"><strong>' + this.purchase_instruction + '</strong> &euro;' + (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.payment_groups_id !== '') {
		temp += '<p>Buy this print online:</p>';
				temp += '<form id="paymentOptions" style="margin:0px;border:0px;" name="paymentOptions">';
		 									temp += '<select class="paymentlink" name="payment_options_id" onchange="updateCartValue($(this.form).next(\'#paymentForm\')[0],this.form.payment_options_id.options[this.form.payment_options_id.options.selectedIndex].value); if(divShowing(\'paymentConfirm\')){fadeOut(\'paymentConfirm\', 3)};">';
		
		temp += getPaymentOptions(this.payment_groups_id);
		temp += '</select>';
		temp += '</form>';
				var item_option  = paymentGroups[this.payment_groups_id].options[0];
		if(paymentOptions[item_option]){
			var item_name  = paymentOptions[item_option].payment_option;
			var amount =  paymentOptions[item_option].price;
		}
			}
		else {
		
	}
	if (this.item_price !== '' || this.payment_groups_id !== '') {
											temp += '<form id="paymentForm" style="margin:0px;border:0px;" name="paymentForm">';
			temp += '	<input type="hidden" name="item_option" value="' + item_option + '">';
			temp += '	<input type="hidden" name="site" value="ANTONCINI">';
			temp += '	<input type="hidden" name="item_number" value="'+ this.id +'">';
			temp += '	<input type="hidden" name="quantity" value="1">';
						temp += '	<input value="Add to cart" id="paymentAddButton" class="button" onmouseover="this.className=\'buttonHi\'\;" onmouseout="this.className=\'button\'\;" type="Button">';
							temp += '	<input value="View cart" id="paymentViewButton" class="button" onmouseover="this.className=\'buttonHi\';" onmouseout="this.className=\'button\';" type="Button" onclick="javascript:window.location=\'cart.html\'">';
			temp += '</form>';
						temp += '<div class="clearing">&nbsp;</div>';
			temp += '<div id="confirmContainer">';
			temp += '<div id="paymentConfirm">Item added to cart</div>';
			temp += '</div>';
			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;
	}
}

			

