/***************************************************************************
* Create a photo object                                                    *
***************************************************************************/
function photo(id, galleries_id, photo_ref, section_code, src, width, height, caption, thumbnail, thumbnail_width, thumbnail_height, home, gallery, description, takendate, photographer, location, item_price, purchase_instruction) {
	this.id = id;
	this.galleries_id = galleries_id;
	this.photo_ref = photo_ref;
	this.section_code = section_code;
	this.src = src;
	this.width = width;
	this.height = height;
	this.caption = caption;
	this.thumbnail = thumbnail;
	this.thumbnail_width = thumbnail_width;
	this.thumbnail_height = thumbnail_height;
	this.home = home;
	this.gallery = gallery;
	this.description = description;
	this.takendate = takendate;
	this.photographer = photographer;
	this.location = location;
	this.item_price = item_price;
	this.purchase_instruction = purchase_instruction;
}
/***************************************************************************
* Create a gallery object                                                  *
***************************************************************************/

function gallery(id,featured_images,title,section_code) {
	this.id = id;
	this.featured_images = featured_images;
	this.title = title;
	this.section_code = section_code;}

/***************************************************************************
* Select a random value from a comma separated list                        *
***************************************************************************/
function randomListVal(list) {
	arrayVals = list.split(',');
	pos = Math.round(Math.random() * (arrayVals.length - 1));
	debug('Returning ' + arrayVals[pos] + ' as random image');
	return arrayVals[pos];
}

/***************************************************************************
* img = reference to image object in which to show image                   *
***************************************************************************/
function showHomeImage(img) {

	imageID = randomListVal('968867');
	for (j = 0; j < photos.length; j++) {
		if (photos[j].id == imageID) {
			if (!basic) {
			img.src = photos[j].src;
			img.width = photos[j].width;
			img.height = photos[j].height;
			}
			else {
				newImage = new Image(photos[j].width,photos[j].height);
				newImage.src = photos[j].src;
				document.images[img.name] = newImage;
				debug(newImage.src);
			}
			break;
		}
	}
}

/***************************************************************************
* Show a random image on home page from featured images                    *
***************************************************************************/
function showHomeImageInline() {
	
	imageID = randomListVal('968867');
	for (j = 0; j < photos.length; j++) {
		if (photos[j].id == imageID) {
			if ('gallery' != '') {
						if (photos[j].galleries_id != '') {
						document.write('<a href="' + photos[j].section_code + '_' + photos[j].galleries_id + '.html">');
						}
						else {
						document.write('<a href="gallery.html">');
						}
			}
			document.write('<img src="' + photos[j].src + '" width="' + photos[j].width + '" height="' + photos[j].height + '" class="mainhomepageimage" id="mainSample" name="mainSample" alt="' + photos[j].caption  + '" border="0">');
			if ('gallery' != '') {
				document.write('</a>');
			}
			break;
		}
	}
	
}

/***************************************************************************
* Show the next image in a gallery.  field = hidden field containing       *
* image_id                                                                 *
*  img = reference to image object in which to show image                  *
***************************************************************************/
function next(field,img) {

	debug('IN next');
	imageID = field.value;
	
	for (j = 0; j < photos.length; j++) {
		if (photos[j].id == imageID) {
			break;
		}
	}
	debug('image is ' + j);
	nextImg = -1;
	k= j + 1;
	while (nextImg < 0) {
		for (; k < photos.length; k++) {
			debug('testing image ' + k + ': gallery = ' + photos[k].galleries_id + '(existing: ' + photos[j].galleries_id + ')');
			if (photos[k].galleries_id == photos[j].galleries_id) {
				nextImg = k;
				debug('setting  nextImg = ' + k);
				break;
			}
		}
		if (nextImg == -1) {
			k = 0;
		}
	}
	if (nextImg != -1) {
		updateImage(nextImg, field,img);
	}


}


/***************************************************************************
* Set a new image on the gallery detail page given its array position      *
***************************************************************************/
function updateImage (nextImg, field,img) {
	debug('Updating image');
	if (!basic && !((0) || (0))) {
		debug('In updateImage');
		debug('setting  img src = ' + photos[nextImg].src);
		
					
			document.getElementById('imagePhoto').innerHTML = '<img class="mainphoto" src="' + photos[nextImg].src + ' " id="mainPic" name="mainPic" width="' + photos[nextImg].width + '" height="' + photos[nextImg].height + '" alt="' + photos[nextImg].caption + '">';
						field.value = photos[nextImg].id;
			document.getElementById('imageTitle').innerHTML = photos[nextImg].caption;
									document.title = 'MARTIN LOWE GRAPHIC DESIGN & ILLUSTRATION: ' + photos[nextImg].caption;
										/* apply 'blank' classname to element where */			if ( photos[nextImg].caption == '') {
				document.getElementById('imageTitle').style.className = 'blank';
			}
			else {
				document.getElementById('imageTitle').style.className = 'normal';
			}
						temp = '';
			if (photos[nextImg].description != '') {
				temp = temp +  '<p id="imageDescription">' + photos[nextImg].description + '</p>';
			}
						if (photos[nextImg].photo_ref != '') {
				temp = temp + '<p class="imageinfo" id="imageRef"><strong>Ref: </strong>' + photos[nextImg].photo_ref + '</p>';
			}
						if (photos[nextImg].takendate != '') {
				debug('Resetting taken date');
				temp = temp + '<p class="imageinfo" id="imageDate"><strong>Date: </strong>' + photos[nextImg].takendate + '</p>';
			}
			
			if (photos[nextImg].location != '') {
				debug('Resetting location');
				temp = temp + '<p class="imageinfo" id="imageLocation"><strong>Location: </strong>' +  photos[nextImg].location + '</p>';
			}
			
			if (photos[nextImg].photographer != '') {
				debug('Resetting photographer');
				temp = temp + '<p class="imageinfo" id="imagePhotographer"><strong>Photographer: </strong>' + photos[nextImg].photographer + '</p>';
			}
			if (temp != '') {				temp = temp + '<div class="spacer"></div>';			}					if (temp == '') {
			document.getElementById('imageDetails').style.display = 'none';
		}
		else {
			document.getElementById('imageDetails').style.display = 'block';
		}
		document.getElementById('imageDetails').innerHTML =temp;	
		
	}
	else {
		debug('Redirecting to id ' + photos[nextImg].id);
		window.location = 'photo_' + photos[nextImg].id + '.html';
	}
}

/***************************************************************************
* Show the previous image for a gallery. field = hidden field containing   *
* image_id                                                                 *
*  img = reference to image object in which to show image                  *
***************************************************************************/
function previous(field,img) {


	imageID = field.value;
	for (j = 0; j < photos.length; j++) {
		if (photos[j].id == imageID) {
			break;
		}
	}
	debug('image is ' + j);
	nextImg = -1;
	k = j -1;
	while (nextImg < 0) {
		for (; k >= 0; k--) {
			if (photos[k].galleries_id == photos[j].galleries_id) {
				nextImg = k;
				break;
			}
		}
		if (nextImg == -1) {
			k = photos.length -1;
		}
	}
	if (nextImg != -1) {
		updateImage(nextImg, field,img);	
	}
}

/***************************************************************************
* 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) {
	debug('Gallery = ' + gallery_id);
	for (i = 0; i < galleries.length; i++) {
		if (galleries[i].id == gallery_id) {
			imageID = randomListVal(galleries[i].featured_images);
				for (j = 0; j < photos.length; j++) {
					if (photos[j].id == imageID) {
						
						img.src = photos[j].thumbnail;
						img.width = photos[j].thumbnail_width;
						img.height = photos[j].thumbnail_height;
						
						break;
					}
				}
			break;
		}
	} 
	}

/***************************************************************************
* If we have dynamic HTML                                                  *
*  replace the galleries link with a list that                             *
* doesn't include the current gallery                                      *
***************************************************************************/
function showGalleries(gallery_id) {
	debug('Showing links for gallery ' + gallery_id);
	
	if (!basic) {
		temp = '';
		for (i = 0; i < galleries.length; i++) {
			debug('Testing gallery ' + galleries[i].id);
			
			if (galleries[i].id != gallery_id) {
				debug('Adding link');
				if (temp != '') {
					temp = temp + ' | ';
				}
				temp = temp + '<a href="gallery_' + galleries[i].id + '.html">' + galleries[i].title + '</a>';
			}
		}
		document.all.galleryLinks.innerHTML = 'Other galleries: ' + temp;
	}
}
/***************************************************************************
* Create the array of Photo objects                                        *
***************************************************************************/
photos = new Array();
photos[0] = new photo(968867,'72814','','gallery','http://www3.clikpic.com/martinlowe/images/REDDRAGON1.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/REDDRAGONthumbnail1.jpg',128, 128,1, 1,'Red Dragon','','','','','');
photos[1] = new photo(969453,'72814','','gallery','http://www3.clikpic.com/martinlowe/images/STGEORGEBADGES.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/STGEORGEBADGESTHUMB.jpg',128, 128,0, 0,'St George Badges','','','','','');
photos[2] = new photo(969462,'72814','','gallery','http://www3.clikpic.com/martinlowe/images/GEORGEANDBABYDRAGON.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/GEORGEANDBABYDRAGONTHUMB.jpg',128, 128,0, 0,'St George and a Friend','','','','','');
photos[3] = new photo(969463,'72814','','gallery','http://www3.clikpic.com/martinlowe/images/KNIGHTS.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/KNIGHTSTHUMB.jpg',130, 130,0, 0,'Brave Knights','','','','','');
photos[4] = new photo(969464,'72814','','gallery','http://www3.clikpic.com/martinlowe/images/GREENDRAGON.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/GREENDRAGONTHUMB.jpg',128, 128,0, 0,'Green Dragon with Sword and Shield','','','','','');
photos[5] = new photo(969510,'72814','','gallery','http://www3.clikpic.com/martinlowe/images/GEORGIESGANG.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/GEORGIESGANGTHUMB.jpg',128, 128,0, 0,'Georgie\'s Gang','','','','','');
photos[6] = new photo(969507,'72814','','gallery','http://www3.clikpic.com/martinlowe/images/SAINTGEORGEWRITTEN.jpg',593,399,'','http://www3.clikpic.com/martinlowe/images/SAINTGEORGEWRITTENTHUMB.jpg',128, 128,0, 0,'St George Logo','','','','','');
photos[7] = new photo(969506,'72814','','gallery','http://www3.clikpic.com/martinlowe/images/GRISU1.jpg',593,399,'','http://www3.clikpic.com/martinlowe/images/GRISUTHUMB1.jpg',128, 128,0, 0,'Dragon in Armour','','','','','');
photos[8] = new photo(969598,'72815','','gallery','http://www3.clikpic.com/martinlowe/images/YELLOWMONSTER.jpg',590,400,'','http://www3.clikpic.com/martinlowe/images/YELLOWMONSTERTHUMB.jpg',128, 128,0, 1,'Calling Planet Earth','','','','','');
photos[9] = new photo(969611,'72815','','gallery','http://www3.clikpic.com/martinlowe/images/SAINTGEORGEWRITTEN1.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/SAINTGEORGEWRITTENTHUMB1.jpg',128, 128,0, 0,'Saint George Logo','','','','','');
photos[10] = new photo(969768,'72815','','gallery','http://www3.clikpic.com/martinlowe/images/3UGLYMONSTERS.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/3UGLYMONSTERSthunb.jpg',128, 128,0, 0,'Three Ugly Monsters','','','','','');
photos[11] = new photo(969631,'72815','','gallery','http://www3.clikpic.com/martinlowe/images/RABBITEARS.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/RABBITEARSTHUMB.jpg',128, 128,0, 0,'Rabbit Ears','','','','','');
photos[12] = new photo(969614,'72815','','gallery','http://www3.clikpic.com/martinlowe/images/BABYMONSTERS.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/BABYMONSTERSTHUMB.jpg',128, 128,0, 0,'Baby Monsters','','','','','');
photos[13] = new photo(969817,'72815','','gallery','http://www3.clikpic.com/martinlowe/images/MYLITTLEMONSTER.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/MYLITTLEMONSTERTHUMB.jpg',128, 128,0, 0,'My Little Monster','','','','','');
photos[14] = new photo(969807,'72815','','gallery','http://www3.clikpic.com/martinlowe/images/MONSTERBADGES.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/MONSTERBADGESTHUMB.jpg',128, 128,0, 0,'Monster Badges','','','','','');
photos[15] = new photo(969613,'72815','','gallery','http://www3.clikpic.com/martinlowe/images/FACEPULLINGMONSTER.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/FACEPULLINGMONSTERTHUMB.jpg',130, 126,0, 0,'Scary Monster','','','','','');
photos[16] = new photo(971446,'72870','','gallery','http://www3.clikpic.com/martinlowe/images/funkymonkey2.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/funkymonkey2thu.jpg',130, 130,0, 1,'Funky Monkey Identity','','','','','');
photos[17] = new photo(971447,'72870','','gallery','http://www3.clikpic.com/martinlowe/images/speedwaychimps.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/speedwaychimpsthu.jpg',128, 128,0, 0,'Speedway Chimps','','','','','');
photos[18] = new photo(971476,'72870','','gallery','http://www3.clikpic.com/martinlowe/images/funkymonkey5.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/funkymonkey5thu.jpg',130, 130,0, 0,'Monkey Drummer','','','','','');
photos[19] = new photo(971449,'72870','','gallery','http://www3.clikpic.com/martinlowe/images/funkymonkey.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/funkymonkeythu.jpg',130, 130,0, 0,'Come And Make Some Music','','','','','');
photos[20] = new photo(971460,'72870','','gallery','http://www3.clikpic.com/martinlowe/images/funkymonkey1.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/funkymonkey1thu.jpg',130, 130,0, 0,'Monkey Nuts','','','','','');
photos[21] = new photo(971470,'72870','','gallery','http://www3.clikpic.com/martinlowe/images/monkeymusic.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/monkeymusicthu.jpg',130, 130,0, 0,'Shake Your Monkey Maker','','','','','');
photos[22] = new photo(971472,'72870','','gallery','http://www3.clikpic.com/martinlowe/images/funkymonkey3.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/funkymonkey3thu.jpg',128, 128,0, 0,'Monkey Puzzle','','','','','');
photos[23] = new photo(971450,'72870','','gallery','http://www3.clikpic.com/martinlowe/images/crazychimpbrand.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/crazychimpbrandthu.jpg',130, 130,0, 0,'Crazy Chimp Brand','','','','','');
photos[24] = new photo(971538,'72871','','gallery','http://www3.clikpic.com/martinlowe/images/moonmutts.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/moonmuttsthu.jpg',130, 130,0, 1,'Bark At The Moon','','','','','');
photos[25] = new photo(972438,'72871','','gallery','http://www3.clikpic.com/martinlowe/images/woofwoofwoof.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/woofwoofwoofthu.jpg',128, 128,0, 0,'Woof Woof Woof!','','','','','');
photos[26] = new photo(972440,'72871','','gallery','http://www3.clikpic.com/martinlowe/images/mysticmutt.jpg',593,374,'','http://www3.clikpic.com/martinlowe/images/mysticmuttthu.jpg',128, 128,0, 0,'Paws For Thought','','','','','');
photos[27] = new photo(972791,'72871','','gallery','http://www3.clikpic.com/martinlowe/images/TICKLEMYTUMMY.jpg',593,374,'','http://www3.clikpic.com/martinlowe/images/TICKLEMYTUMMYthu.jpg',128, 128,0, 0,'Watch Me Howl!','','','','','');
photos[28] = new photo(971550,'72871','','gallery','http://www3.clikpic.com/martinlowe/images/woofwoof2.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/woofwoofthu1.jpg',130, 130,0, 0,'Woof Woof Brum Brum!','','','','','');
photos[29] = new photo(972764,'72871','','gallery','http://www3.clikpic.com/martinlowe/images/MrJosephs.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/MrJosephsTHU.jpg',128, 130,0, 0,'Mr Josephs NYC','','','','','');
photos[30] = new photo(977848,'72871','','gallery','http://www3.clikpic.com/martinlowe/images/bonesforyou.jpg',593,374,'','http://www3.clikpic.com/martinlowe/images/bonesforyouthu.jpg',130, 130,0, 0,'Bones for you!','','','','','');
photos[31] = new photo(972793,'72871','','gallery','http://www3.clikpic.com/martinlowe/images/doggiedaycare.jpg',593,374,'','http://www3.clikpic.com/martinlowe/images/doggiedaycareTHU.jpg',130, 130,0, 0,'Home From Home!','','','','','');
photos[32] = new photo(970434,'72983','','gallery','http://www3.clikpic.com/martinlowe/images/UPTONOGOODDISTRESSEDBETTER.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/UPTONOGOODTHU.jpg',128, 128,0, 1,'Up To No Good','','','','','');
photos[33] = new photo(970436,'72983','','gallery','http://www3.clikpic.com/martinlowe/images/NAUGHTYBUTNICE.jpg',590,400,'','http://www3.clikpic.com/martinlowe/images/NAUGHTYBUTNICETHU.jpg',128, 128,0, 0,'Naughty But Nice!','','','','','');
photos[34] = new photo(970437,'72983','','gallery','http://www3.clikpic.com/martinlowe/images/THENAMESTROUBLE.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/THENAMESTROUBLETHU.jpg',130, 130,0, 0,'The Name\'s Trouble...','','','','','');
photos[35] = new photo(970439,'72983','','gallery','http://www3.clikpic.com/martinlowe/images/COMEONLETSPLAY.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/COMEONLETSPLAYTHU.jpg',130, 130,0, 0,'Come On Lets Play','','','','','');
photos[36] = new photo(970463,'72983','','gallery','http://www3.clikpic.com/martinlowe/images/KINGOFCUDDLESDISTRESSEDBETTER.jpg',600,391,'','http://www3.clikpic.com/martinlowe/images/KINGOFCUDDLESTHU.jpg',130, 130,0, 0,'King Of Cuddles','','','','','');
photos[37] = new photo(970464,'72983','','gallery','http://www3.clikpic.com/martinlowe/images/TURTLEYCOOL.jpg',593,386,'','http://www3.clikpic.com/martinlowe/images/TURTLEYCOOLTHU2.jpg',128, 128,0, 0,'Turtley Cool','','','','','');
photos[38] = new photo(970466,'72983','','gallery','http://www3.clikpic.com/martinlowe/images/WOTCHA DISTRESSED BETTER copy.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/WOTCHADISTRESSEDBETTERTHU.jpg',128, 128,0, 0,'Wotcha!','','','','','');
photos[39] = new photo(970468,'72983','','gallery','http://www3.clikpic.com/martinlowe/images/KINGOFCUDDLES2.jpg',593,388,'','http://www3.clikpic.com/martinlowe/images/KINGOFCUDDLES2THU.jpg',130, 130,0, 0,'King Of Cuddles','','','','','');
photos[40] = new photo(970575,'72993','','gallery','http://www3.clikpic.com/martinlowe/images/dufferlittlerobot.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/dufferlittlerobotthu.jpg',130, 130,0, 1,'Little Robot','','','','','');
photos[41] = new photo(3304119,'72993','','gallery','http://www3.clikpic.com/martinlowe/images/2furtherrobots.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/2furtherrobots_thumb.jpg',128, 128,0, 0,'','','','','','');
photos[42] = new photo(970603,'72993','','gallery','http://www3.clikpic.com/martinlowe/images/theycamefromaplanetcalledplay.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/theycamefromaplanetcalledplaythu.jpg',130, 130,0, 0,'They Came From A Planet Called Play','','','','','');
photos[43] = new photo(970607,'72993','','gallery','http://www3.clikpic.com/martinlowe/images/robotbadges.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/robotbadgesthu.jpg',130, 130,0, 0,'Robot Badges','','','','','');
photos[44] = new photo(972761,'72993','','gallery','http://www3.clikpic.com/martinlowe/images/robotpower1.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/robotpowerthu1.jpg',130, 130,0, 0,'Robot Power Logo','','','','','');
photos[45] = new photo(970628,'72993','','gallery','http://www3.clikpic.com/martinlowe/images/spacescout.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/spacescoutthu.jpg',130, 130,0, 0,'Space Scout','','','','','');
photos[46] = new photo(970617,'72993','','gallery','http://www3.clikpic.com/martinlowe/images/robotpower2.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/robotpower2thu.jpg',130, 130,0, 0,'Robot Power','','','','','');
photos[47] = new photo(972444,'72993','','gallery','http://www3.clikpic.com/martinlowe/images/robotcity1.jpg',592,400,'','http://www3.clikpic.com/martinlowe/images/robotcitythu1.jpg',130, 130,0, 0,'Robot Rampage','','','','','');
photos[48] = new photo(972895,'73121','','gallery','http://www3.clikpic.com/martinlowe/images/CUTEASABUTTON.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/CUTETHU.jpg',130, 130,0, 0,'Cute As a Button Club - Founder Member.','','','','','');
photos[49] = new photo(972897,'73121','','gallery','http://www3.clikpic.com/martinlowe/images/MASTEROFMAYHEM.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/MASTEROFMAYHEMTHU.jpg',130, 130,0, 0,'Master Of Mayhem','','','','','');
photos[50] = new photo(972892,'73121','','gallery','http://www3.clikpic.com/martinlowe/images/APPLE.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/APPLETHU.jpg',130, 130,0, 0,'The Apple Of My Mummy\'s Eye','','','','','');
photos[51] = new photo(973085,'73121','','gallery','http://www3.clikpic.com/martinlowe/images/TICKETTOFUN.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/TICKETTOFUNTHU.jpg',128, 128,0, 0,'All Aboard for a Funtime','','','','','');
photos[52] = new photo(972924,'73121','','gallery','http://www3.clikpic.com/martinlowe/images/MRMAYHEM.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/MRMAYHEMTHU.jpg',130, 130,0, 0,'My Mayhem At Your Service','','','','','');
photos[53] = new photo(972934,'73121','','gallery','http://www3.clikpic.com/martinlowe/images/SUNSHINE.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/SUNSHINETHU.jpg',130, 130,0, 1,'Mummy\'s Little Sunshine','','','','','');
photos[54] = new photo(972893,'73121','','gallery','http://www3.clikpic.com/martinlowe/images/CRASH.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/CRASHTHU.jpg',130, 130,0, 0,'Crash Bang Wallop Here I Come!','','','','','');
photos[55] = new photo(972930,'73121','','gallery','http://www3.clikpic.com/martinlowe/images/NOISY.jpg',593,400,'','http://www3.clikpic.com/martinlowe/images/NOISYTHU.jpg',130, 130,0, 0,'Noisy - Me?','','','','','');

/***************************************************************************
* Create the array of Gallery objects                                      *
***************************************************************************/
galleries = new Array();
galleries[0] = new gallery(72814,'968867','dragons','gallery');
galleries[1] = new gallery(72815,'969598','monsters','gallery');
galleries[2] = new gallery(72870,'971446','monkeys','gallery');
galleries[3] = new gallery(72871,'971538','dogs','gallery');
galleries[4] = new gallery(72983,'970434','sea creatures','gallery');
galleries[5] = new gallery(72993,'970575','robots','gallery');
galleries[6] = new gallery(73121,'972934','logo t-shirts','gallery');


