window.thumbnails = new Object();
												thumbnails[7195971] = new thumbnail(7195971,'','Rebecca Adlington','Adlington_4web_thumb.jpg',130, 79,15,'							photo_7195971.html');
												thumbnails[186270] = new thumbnail(186270,'16817','','IMG_1880 copy_thumb.jpg',130, 168,15,'							photo_186270.html');
												thumbnails[186350] = new thumbnail(186350,'16824','','Novelli435 copy_thumb.jpg',130, 71,15,'							photo_186350.html');
												thumbnails[186367] = new thumbnail(186367,'16824','','warleyhospital copy_thumb.jpg',130, 87,15,'							photo_186367.html');
												thumbnails[189906] = new thumbnail(189906,'16825','Norway','Norway1925_thumb.jpg',130, 87,15,'							photo_189906.html');
												thumbnails[210950] = new thumbnail(210950,'16817','','IMG_7752_thumb.JPG',130, 168,15,'							photo_210950.html');
												thumbnails[210952] = new thumbnail(210952,'16817','','IMG_7753_thumb.JPG',130, 170,15,'							photo_210952.html');
												thumbnails[210953] = new thumbnail(210953,'16817','','IMG_7754_thumb.JPG',130, 168,15,'							photo_210953.html');
												thumbnails[532469] = new thumbnail(532469,'16821','Stephen Fry & Millie','Kingdom_Specials036 copy_thumb.jpg',130, 120,15,'							photo_532469.html');
												thumbnails[532474] = new thumbnail(532474,'16821','Heartbeat','Heartbeat_Specials062 copy_thumb.jpg',130, 87,15,'							photo_532474.html');
												thumbnails[734979] = new thumbnail(734979,'16817','','TravelCover_thumb.jpg',130, 163,15,'							photo_734979.html');
												thumbnails[750300] = new thumbnail(750300,'16817','Kevin McCloud','IMG_9421_thumb.JPG',130, 159,15,'							photo_750300.html');
												thumbnails[925463] = new thumbnail(925463,'16823','Sword son','SwordSon10_thumb.jpg',130, 87,15,'							photo_925463.html');
												thumbnails[925471] = new thumbnail(925471,'16824','swordson location','SwordSon_location_thumb.jpg',130, 87,15,'							photo_925471.html');
												thumbnails[925478] = new thumbnail(925478,'16817','Sunday Times \'Best 100 Companies\' 07','Coverpic_thumb.jpg',130, 172,15,'							photo_925478.html');
												thumbnails[925485] = new thumbnail(925485,'16819','Roland Nichols','roland008 copy_thumb.jpg',130, 153,15,'							photo_925485.html');
												thumbnails[1825689] = new thumbnail(1825689,'16822','','3663 MONO AD FOR MT_thumb.jpg',130, 87,15,'							photo_1825689.html');
												thumbnails[1825690] = new thumbnail(1825690,'16822','','3663_Banbury485_Finished_thumb.jpg',130, 99,15,'							photo_1825690.html');
												thumbnails[1825692] = new thumbnail(1825692,'16821',' Anna Madeley  \"Affinity\" Box TV for ITV','Affinity394_thumb.jpg',130, 195,15,'							photo_1825692.html');
												thumbnails[1825694] = new thumbnail(1825694,'16822','','ARGOS_thumb.jpg',130, 87,15,'							photo_1825694.html');
												thumbnails[1825697] = new thumbnail(1825697,'16821','','BadMothers014-2 copy_thumb.jpg',130, 89,15,'							photo_1825697.html');
												thumbnails[1825700] = new thumbnail(1825700,'16819','Stephen Fry','Fry031_thumb.jpg',130, 195,15,'							photo_1825700.html');
												thumbnails[1825703] = new thumbnail(1825703,'16819','Lewis Hamilton','Hamilton_thumb.jpg',130, 176,15,'							photo_1825703.html');
												thumbnails[1825709] = new thumbnail(1825709,'16821','\"The Last Enemy\" Box TV for BBC','Last_Enemy062_thumb.jpg',130, 195,15,'							photo_1825709.html');
												thumbnails[1825713] = new thumbnail(1825713,'16821','\"The Last Enemy\" Box TV for BBC','Last_Enemy084_thumb.jpg',130, 75,15,'							photo_1825713.html');
												thumbnails[1825725] = new thumbnail(1825725,'16823','Britains Oldest Bikers  Sunday Times','Oldest_Bikers22 copy_1_thumb.jpg',130, 87,15,'							photo_1825725.html');
												thumbnails[1825728] = new thumbnail(1825728,'16822','Scania (GB) Ad Campaign 08','PAUL ABBOTT AD FOR MT_thumb.jpg',130, 86,15,'							photo_1825728.html');
												thumbnails[1862794] = new thumbnail(1862794,'16817','Richard Hammond for Scene Scania','Covers405_web_thumb.jpg',130, 164,15,'							photo_1862794.html');
												thumbnails[1862795] = new thumbnail(1862795,'16817','Tom Cassells for Scene Scania','Covers407_web_thumb.jpg',130, 167,15,'							photo_1862795.html');
												thumbnails[1862800] = new thumbnail(1862800,'16817','Dame Kelly Holmes for Scene Scania','Covers409web_thumb.jpg',130, 166,15,'							photo_1862800.html');
												thumbnails[182762] = new thumbnail(182762,'16819','Alastair Mackenzie','AlMckenzie_thumb.jpg',130, 94,15,'							photo_182762.html');
												thumbnails[182763] = new thumbnail(182763,'16819','Charlton Heston','Charlton_Heston_thumb.jpg',130, 175,15,'							photo_182763.html');
												thumbnails[182766] = new thumbnail(182766,'16819','Kristen Scott-Thomas','KristenScottThomas_thumb.jpg',130, 138,15,'							photo_182766.html');
												thumbnails[182767] = new thumbnail(182767,'16819','Gene Wilder','Gene_Wilder_thumb.jpg',130, 169,15,'							photo_182767.html');
												thumbnails[182769] = new thumbnail(182769,'16819','Liza Minelli','Liza_Minelli_thumb.jpg',130, 160,15,'							photo_182769.html');
												thumbnails[182783] = new thumbnail(182783,'16819','Madonna','Madonna_thumb.jpg',130, 161,15,'							photo_182783.html');
												thumbnails[182790] = new thumbnail(182790,'16819','Nicholas Anelka','Nicholas_Anelka_thumb.jpg',130, 170,15,'							photo_182790.html');
												thumbnails[182791] = new thumbnail(182791,'16819','Robert Lindsay','Robert_Lindsay_thumb.jpg',130, 95,15,'							photo_182791.html');
												thumbnails[182792] = new thumbnail(182792,'16819','Ron Atkinson','Ron_Atkinson_thumb.jpg',130, 97,15,'							photo_182792.html');
												thumbnails[182794] = new thumbnail(182794,'16819','Steve Pemberton','Pemberton139_4web_thumb.jpg',130, 87,15,'							photo_182794.html');
												thumbnails[182797] = new thumbnail(182797,'16820','Blue Suit','blue suit copy_thumb.jpg',130, 174,15,'							photo_182797.html');
												thumbnails[711777] = new thumbnail(711777,'16819','Joseph Fiennes','Jo_Feinnes32 web_thumb.jpg',130, 182,15,'							photo_711777.html');
												thumbnails[925459] = new thumbnail(925459,'16822','Argos for Scania GB','Argos290_thumb.jpg',130, 99,15,'							photo_925459.html');
												thumbnails[1425561] = new thumbnail(1425561,'16821','Timothy Spall \"Gunrush\" for ITV','Gunrush696_4web_thumb.jpg',130, 102,15,'							photo_1425561.html');
												thumbnails[182800] = new thumbnail(182800,'16820','Bridal Car','BridalFashion_thumb.jpg',130, 161,15,'							photo_182800.html');
												thumbnails[182803] = new thumbnail(182803,'16820','Button Hole','buttonhole_thumb.jpg',130, 191,15,'							photo_182803.html');
												thumbnails[182833] = new thumbnail(182833,'16819','Gina Bellman, Actress','Gina_Bellman_thumb.jpg',130, 191,15,'							photo_182833.html');
												thumbnails[2426180] = new thumbnail(2426180,'16819','Ben Whishaw','Ben_Whishaw9656_thumb.jpg',130, 161,15,'							photo_2426180.html');
												thumbnails[182834] = new thumbnail(182834,'16819','Kerry Condon, Actress. recent credits: \"ROME\"','KerryCondon_thumb.jpg',130, 177,15,'							photo_182834.html');
												thumbnails[182835] = new thumbnail(182835,'16820','Laura Bailey','Laura_Bailey_thumb.jpg',130, 170,15,'							photo_182835.html');
												thumbnails[182836] = new thumbnail(182836,'16820','Pink Cadillac','Pink_Cadillac_thumb.jpg',130, 190,15,'							photo_182836.html');
												thumbnails[182837] = new thumbnail(182837,'16822','Socks by Scania','ScaniaSocks_thumb.jpg',130, 89,15,'							photo_182837.html');
												thumbnails[182839] = new thumbnail(182839,'16820','Spring Fashion','springfashion_thumb.jpg',130, 176,15,'							photo_182839.html');
												thumbnails[182840] = new thumbnail(182840,'16821','Ab Fab','AbFab _thumb.jpg',130, 148,15,'							photo_182840.html');
												thumbnails[182842] = new thumbnail(182842,'16821','Amnesia','Amnesia_thumb.jpg',130, 87,15,'							photo_182842.html');
												thumbnails[182843] = new thumbnail(182843,'16821','Crown and Country','CarltonTelevision_thumb.jpg',130, 149,15,'							photo_182843.html');
												thumbnails[182845] = new thumbnail(182845,'16821','Murder Most Horrid','Michael_Elphic_thumb.jpg',130, 94,15,'							photo_182845.html');
												thumbnails[182877] = new thumbnail(182877,'16821','Only Fools and Horses','OnlyFoolsandHorses_thumb.jpg',130, 160,15,'							photo_182877.html');
												thumbnails[182942] = new thumbnail(182942,'16821','Monarch of the Glen','Richard_Briars_thumb.jpg',130, 174,15,'							photo_182942.html');
												thumbnails[182943] = new thumbnail(182943,'16821','Rose and Maloney','Rose_and_Maloney_thumb.jpg',130, 86,15,'							photo_182943.html');
												thumbnails[182945] = new thumbnail(182945,'16821','The Entertainer','The_Entertainer_thumb.jpg',130, 104,15,'							photo_182945.html');
												thumbnails[182948] = new thumbnail(182948,'16821','Ultimate Force','UltimateForce_thumb.jpg',130, 75,15,'							photo_182948.html');
												thumbnails[182953] = new thumbnail(182953,'16821','Wicked Lady','Wicked_Lady_thumb.jpg',130, 106,15,'							photo_182953.html');
												thumbnails[182956] = new thumbnail(182956,'16822','Carebase Ltd','CareHomes_thumb.jpg',130, 93,15,'							photo_182956.html');
												thumbnails[182959] = new thumbnail(182959,'16822','Virgin Books','Freddie Starr copy_thumb.jpg',130, 197,15,'							photo_182959.html');
												thumbnails[182986] = new thumbnail(182986,'16822','Scania (GB) Ltd','Scania_7254 copy_thumb.jpg',130, 73,15,'							photo_182986.html');
												thumbnails[182991] = new thumbnail(182991,'16822','Sir John Chisolm','Sir_John_Chisolm2128 copy_thumb.jpg',130, 80,15,'							photo_182991.html');
												thumbnails[182997] = new thumbnail(182997,'16822','Sony Technology','sony phone copy_thumb.jpg',130, 163,15,'							photo_182997.html');
												thumbnails[183002] = new thumbnail(183002,'16822','Scania (GB) Ltd','Truck_Coach copy_thumb.jpg',130, 87,15,'							photo_183002.html');
												thumbnails[183004] = new thumbnail(183004,'16822','Kodak Weather-Proof Cameras','wet camera copy_thumb.jpg',130, 175,15,'							photo_183004.html');
												thumbnails[183007] = new thumbnail(183007,'16822','ICI Zephex','Zephex4_32 copy_thumb.jpg',130, 199,15,'							photo_183007.html');
												thumbnails[183080] = new thumbnail(183080,'16823','Catwalk for Kids','Catwalk_Kids_thumb.jpg',130, 79,15,'							photo_183080.html');
												thumbnails[183082] = new thumbnail(183082,'16823','Elton John','Elton_John_thumb.jpg',130, 87,15,'							photo_183082.html');
												thumbnails[183087] = new thumbnail(183087,'16823','Gloria Hunniford','Gloria_Hunniford_thumb.jpg',130, 163,15,'							photo_183087.html');
												thumbnails[183092] = new thumbnail(183092,'16823','Hen Night','Hen_Night_thumb.jpg',130, 99,15,'							photo_183092.html');
												thumbnails[183160] = new thumbnail(183160,'16823','Mick Jagger','jagger copy_thumb.jpg',130, 223,15,'							photo_183160.html');
												thumbnails[183172] = new thumbnail(183172,'16823','John Gordon-Sinclair','John_Gordon_Sinclair_thumb.jpg',130, 169,15,'							photo_183172.html');
												thumbnails[183177] = new thumbnail(183177,'16823','Pearl Harbor Veteran','PearlHarborVet_thumb.jpg',130, 83,15,'							photo_183177.html');
												thumbnails[183181] = new thumbnail(183181,'16823','Ross Kemp ','Ross_Kemp_thumb.jpg',130, 170,15,'							photo_183181.html');
												thumbnails[183202] = new thumbnail(183202,'16823','Traffic Warden','Traffic_Warden_thumb.jpg',130, 157,15,'							photo_183202.html');
												thumbnails[183204] = new thumbnail(183204,'16825','Balloon Seller, Turkey','balloon_seller_thumb.jpg',130, 92,15,'							photo_183204.html');
												thumbnails[183205] = new thumbnail(183205,'16825','Red Sea, Egypt','DivingRedSea_thumb.jpg',130, 182,15,'							photo_183205.html');
												thumbnails[183206] = new thumbnail(183206,'16825','Eastbourne.','EastbourneLadies_thumb.jpg',130, 140,15,'							photo_183206.html');
												thumbnails[183209] = new thumbnail(183209,'16825','Cowboy, Hawaii','HawaiianCowboy_thumb.jpg',130, 88,15,'							photo_183209.html');
												thumbnails[183213] = new thumbnail(183213,'16825','Queensland','koala_thumb.jpg',130, 195,15,'							photo_183213.html');
												thumbnails[183215] = new thumbnail(183215,'16825','Paris.','PARIS_88_thumb.jpg',130, 99,15,'							photo_183215.html');
												thumbnails[183217] = new thumbnail(183217,'16825','Pearl Harbour','PearlHarbor_thumb.jpg',130, 176,15,'							photo_183217.html');
												thumbnails[186139] = new thumbnail(186139,'16825','Hawaii','Tourist_thumb.jpg',130, 229,15,'							photo_186139.html');
												thumbnails[186140] = new thumbnail(186140,'16825','Westminster ','Westminster_thumb.jpg',130, 87,15,'							photo_186140.html');
												thumbnails[186186] = new thumbnail(186186,'16825','Orphan, Borneo','Monkey_thumb.jpg',130, 90,15,'							photo_186186.html');
												thumbnails[186262] = new thumbnail(186262,'16817','','DSCN2926 copy_thumb.jpg',130, 169,15,'							photo_186262.html');
												thumbnails[186264] = new thumbnail(186264,'16817','','IMG_1871 copy_thumb.jpg',130, 169,15,'							photo_186264.html');
												thumbnails[186265] = new thumbnail(186265,'16817','','IMG_1872 copy_thumb.jpg',130, 143,15,'							photo_186265.html');
												thumbnails[186267] = new thumbnail(186267,'16817','','IMG_1875 copy_thumb.jpg',130, 144,15,'							photo_186267.html');
												thumbnails[186269] = new thumbnail(186269,'16817','','IMG_1878 copy_thumb.jpg',130, 146,15,'							photo_186269.html');
												thumbnails[186273] = new thumbnail(186273,'16817','','IMG_1885 copy_thumb.jpg',130, 169,15,'							photo_186273.html');
												thumbnails[186274] = new thumbnail(186274,'16817','','IMG_1888 copy_thumb.jpg',130, 167,15,'							photo_186274.html');
												thumbnails[186275] = new thumbnail(186275,'16817','','IMG_1891 copy_thumb.jpg',130, 150,15,'							photo_186275.html');
												thumbnails[186277] = new thumbnail(186277,'16817','','TVTimes21Jan copy_thumb.jpg',130, 180,15,'							photo_186277.html');
												thumbnails[186330] = new thumbnail(186330,'16824','','Barn_thumb.jpg',130, 93,15,'							photo_186330.html');
												thumbnails[186336] = new thumbnail(186336,'16824','','Cowan1412 copy_thumb.jpg',130, 87,15,'							photo_186336.html');
												thumbnails[186342] = new thumbnail(186342,'16824','','EmmaBridgewater4461 copy_thumb.jpg',130, 185,15,'							photo_186342.html');
												thumbnails[186346] = new thumbnail(186346,'16824','','M&S_thumb.jpg',130, 87,15,'							photo_186346.html');
												thumbnails[186353] = new thumbnail(186353,'16824','','Radiator1_thumb.jpg',130, 221,15,'							photo_186353.html');
												thumbnails[186355] = new thumbnail(186355,'16824','','Somersham10 copy_thumb.jpg',130, 87,15,'							photo_186355.html');
												thumbnails[189905] = new thumbnail(189905,'16822','People Bank','tanya brier_thumb.jpg',130, 213,15,'							photo_189905.html');
												thumbnails[186370] = new thumbnail(186370,'16824','','ShowerHead_thumb.jpg',130, 87,15,'							photo_186370.html');
												thumbnails[189909] = new thumbnail(189909,'16819','Conran','Conran7105 copy_thumb.jpg',130, 78,15,'							photo_189909.html');
												thumbnails[189910] = new thumbnail(189910,'16821','\"A Touch of Frost\" ITV','Frost3shot_4web__copy_thumb.jpg',130, 170,15,'							photo_189910.html');
												thumbnails[189913] = new thumbnail(189913,'16821','Frost','frost copy_thumb.jpg',130, 195,15,'							photo_189913.html');
												thumbnails[190399] = new thumbnail(190399,'16825','newyork ','NewYorkDiner copy_thumb.jpg',130, 170,15,'							photo_190399.html');
												thumbnails[190979] = new thumbnail(190979,'16823','The hunt','Hunting copy_thumb.jpg',130, 87,15,'							photo_190979.html');
												thumbnails[198784] = new thumbnail(198784,'16820','','fireescape copy_thumb.jpg',130, 137,15,'							photo_198784.html');
												thumbnails[198785] = new thumbnail(198785,'16820','','ladder copy_thumb.jpg',130, 176,15,'							photo_198785.html');
												thumbnails[198787] = new thumbnail(198787,'16820','Everglades','woodpile copy_thumb.jpg',130, 210,15,'							photo_198787.html');
												thumbnails[198788] = new thumbnail(198788,'16820','Pink theme','cadigirl copy_thumb.jpg',130, 150,15,'							photo_198788.html');
												thumbnails[198789] = new thumbnail(198789,'16820','Gator country','swampgirl copy_thumb.jpg',130, 153,15,'							photo_198789.html');
												thumbnails[198791] = new thumbnail(198791,'16820','Tiger','tigerfashion copy_thumb.jpg',130, 158,15,'							photo_198791.html');
												thumbnails[198792] = new thumbnail(198792,'16820','Street Fashion','streetfashion copy_thumb.jpg',130, 167,15,'							photo_198792.html');
												thumbnails[198793] = new thumbnail(198793,'16820','Blue Theme','bluedress copy_thumb.jpg',130, 126,15,'							photo_198793.html');
												thumbnails[198806] = new thumbnail(198806,'16819','Felix Dennis','Dennis_watercolour_thumb.jpg',130, 176,15,'							photo_198806.html');
												thumbnails[198807] = new thumbnail(198807,'16822','Tabloid WallStreet','Wall_Street_Journal_thumb.jpg',130, 87,15,'							photo_198807.html');
												thumbnails[198808] = new thumbnail(198808,'16823','Geek','GeekDancing copy_thumb.jpg',130, 180,15,'							photo_198808.html');
												thumbnails[198809] = new thumbnail(198809,'16823','laughing Lions','RugbySpecial138_thumb.jpg',130, 95,15,'							photo_198809.html');
												thumbnails[204831] = new thumbnail(204831,'16819','Robert Pires','RobertPires copy_thumb.jpg',130, 161,15,'							photo_204831.html');
												thumbnails[204832] = new thumbnail(204832,'16823','Feeding Time','CopwithSweet copy_thumb.jpg',130, 189,15,'							photo_204832.html');
												thumbnails[204833] = new thumbnail(204833,'16823','Tara','TaraPT copy_thumb.jpg',130, 93,15,'							photo_204833.html');
												thumbnails[204834] = new thumbnail(204834,'16819','Isabella Blow','IsabellaBlow copy_thumb.jpg',130, 184,15,'							photo_204834.html');
												thumbnails[204836] = new thumbnail(204836,'16819','Graham Norton','GrahamNorton copy_thumb.jpg',130, 176,15,'							photo_204836.html');
												thumbnails[204837] = new thumbnail(204837,'16819','Margaret Drabble','Drabble copy_thumb.jpg',130, 202,15,'							photo_204837.html');
												thumbnails[204840] = new thumbnail(204840,'16823','Mareen Lipman','Lipman copy_thumb.jpg',130, 93,15,'							photo_204840.html');
												thumbnails[204841] = new thumbnail(204841,'16819','Jane Horrocks','Jane Horrocks copy_thumb.jpg',130, 175,15,'							photo_204841.html');
												thumbnails[210943] = new thumbnail(210943,'16817','','IMG_7747_thumb.JPG',130, 167,15,'							photo_210943.html');
												thumbnails[210945] = new thumbnail(210945,'16817','','IMG_7748_thumb.JPG',130, 168,15,'							photo_210945.html');
												thumbnails[210946] = new thumbnail(210946,'16817','','IMG_7749_thumb.JPG',130, 152,15,'							photo_210946.html');
												thumbnails[210948] = new thumbnail(210948,'16817','','IMG_7750_thumb.JPG',130, 159,15,'							photo_210948.html');
												thumbnails[210949] = new thumbnail(210949,'16817','','IMG_7751_thumb.JPG',130, 165,15,'							photo_210949.html');
												thumbnails[210955] = new thumbnail(210955,'16817','','IMG_7755_thumb.JPG',130, 166,15,'							photo_210955.html');
												thumbnails[277048] = new thumbnail(277048,'16819','Ronan Keating','Ronan_Keating_thumb.jpg',130, 87,15,'							photo_277048.html');
												thumbnails[282882] = new thumbnail(282882,'16817','TV Times','tvtimesCover001 copy_thumb.jpg',130, 179,15,'							photo_282882.html');

/***************************************************************************
* Create the array of Gallery objects                                      *
***************************************************************************/
var galleries = new Object();
				  					galleries[16819] = new gallery(16819,'2426180,1825700','Portraits','gallery',[925485,1825700,1825703,182762,182763,182766,182767,182769,182783,182790,182791,182792,182794,711777,182833,2426180,182834,189909,198806,204831,204834,204836,204837,204841,277048],0, 0, '', '																																																																																																							gallery_16819.html',0,0);
				  					galleries[16820] = new gallery(16820,'182800','Fashion','gallery',[182797,182800,182803,182835,182836,182839,198784,198785,198787,198788,198789,198791,198792,198793],0, 0, '', '																																																																																																							gallery_16820.html',0,0);
				  					galleries[16821] = new gallery(16821,'532469','Film & TV','gallery',[532469,532474,1825692,1825697,1825709,1825713,1425561,182840,182842,182843,182845,182877,182942,182943,182945,182948,182953,189910,189913],0, 0, '', '																																																																																																							gallery_16821.html',0,0);
				  					galleries[16822] = new gallery(16822,'1825728,1825694,1825690,1825689,925459,198807,189905,183007,183004,183002','Commercial / Advertising','gallery',[1825689,1825690,1825694,1825728,925459,182837,182956,182959,182986,182991,182997,183002,183004,183007,189905,198807],0, 0, '', '																																																																																																							gallery_16822.html',0,0);
				  					galleries[16823] = new gallery(16823,'198808','Editorial','gallery',[925463,1825725,183080,183082,183087,183092,183160,183172,183177,183181,183202,190979,198808,198809,204832,204833,204840],0, 0, '', '																																																																																																							gallery_16823.html',0,0);
				  					galleries[16817] = new gallery(16817,'282882,186267','Covers','gallery',[186270,210950,210952,210953,734979,750300,925478,1862794,1862795,1862800,186262,186264,186265,186267,186269,186273,186274,186275,186277,210943,210945,210946,210948,210949,210955,282882],0, 0, '', '																																																																																																							gallery_16817.html',0,0);
				  					galleries[16824] = new gallery(16824,'925471,186370,186367,186355,186353,186350,186346,186342,186336,186330','Interiors','gallery',[186350,186367,925471,186330,186336,186342,186346,186353,186355,186370],0, 0, '', '																																																																																																							gallery_16824.html',0,0);
				  					galleries[16825] = new gallery(16825,'186186','Travel','gallery',[189906,183204,183205,183206,183209,183213,183215,183217,186139,186140,186186,190399],0, 0, '', '																																																																																																							gallery_16825.html',0,0);
/***************************************************************************
* Create the array of image sets                                           *
***************************************************************************/
var imageSets = new Object();
imageSets[1] = '186186';
imageSets[2] = '2426180,1825700,532469,282882,198808,186267,186186,182800';
imageSets[3] = '7195971,2426180,1862800,1862795,1862794,1825728,1825725,1825713,1825709,1825703,1825700,1825697,1825694,1825692,1825690,1825689,1425561,925485,925478,925471,925463,925459,750300,734979,711777,532474,532469,282882,277048,210955,210953,210952,210950,210949,210948,210946,210945,210943,204841,204840,204837,204836,204834,204833,204832,204831,198809,198808,198807,198806';
 /***************************************************************************
* Get a server path given an ID                                            *
***************************************************************************/
function getServerPath(server_id) {
	var val = -1;
		switch (server_id) {
		case 21:
		val = 'http://www6.clikpic.com/bourdillon/images';
		break;
	}
		switch (server_id) {
		case 1:
		val = 'http://www1.clikpic.com/bourdillon/images';
		break;
	}
		switch (server_id) {
		case 2:
		val = 'http://admin.clikpic.com/bourdillon/images';
		break;
	}
		switch (server_id) {
		case 24:
		val = 'http://tpc15/clikpic/bourdillon/images';
		break;
	}
		switch (server_id) {
		case 4:
		val = 'http://www.clikchurch.com/bourdillon/images';
		break;
	}
		switch (server_id) {
		case 5:
		val = 'http://www2.clikpic.com/bourdillon/images';
		break;
	}
		switch (server_id) {
		case 22:
		val = 'http://tpc5/clikpic/bourdillon/images';
		break;
	}
		switch (server_id) {
		case 23:
		val = 'http://tpc10/clikpic/bourdillon/images';
		break;
	}
		switch (server_id) {
		case 25:
		val = 'http://tpc16/clikpic/bourdillon/images';
		break;
	}
		switch (server_id) {
		case 40:
		val = 'http://www11.clikpic.com/bourdillon/images';
		break;
	}
		switch (server_id) {
		case 15:
		val = 'http://www3.clikpic.com/bourdillon/images';
		break;
	}
		switch (server_id) {
		case 18:
		val = 'http://www4.clikpic.com/bourdillon/images';
		break;
	}
		switch (server_id) {
		case 19:
		val = 'http://www5.clikpic.com/bourdillon/images';
		break;
	}
		switch (server_id) {
		case 31:
		val = 'http://www7.clikpic.com/bourdillon/images';
		break;
	}
		switch (server_id) {
		case 32:
		val = 'http://admin2.clikpic.com/bourdillon/images';
		break;
	}
		switch (server_id) {
		case 33:
		val = 'http://www8.clikpic.com/bourdillon/images';
		break;
	}
		switch (server_id) {
		case 34:
		val = 'http://www9.clikpic.com/bourdillon/images';
		break;
	}
		switch (server_id) {
		case 35:
		val = 'http://admin3.clikpic.com/bourdillon/images';
		break;
	}
		switch (server_id) {
		case 37:
		val = 'http://admin4.clikpic.com/bourdillon/images';
		break;
	}
		switch (server_id) {
		case 38:
		val = 'http://admin5.clikpic.com/bourdillon/images';
		break;
	}
		switch (server_id) {
		case 39:
		val = 'http://www10.clikpic.com/bourdillon/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 && backgrounds[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:'',
                    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 (!basic) {
    if (op.updateHash && clik.getIDInUrl(location.href,'photo') != op.nextPhoto.id) {
		clik.changeHash('photos_id=' + op.nextPhoto.id, true);
    }
				
    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.$title.length > 0) {
  		op.$title.fadeGalleryDetails(photoCaption, op.speed);
    }
        if (op.updateDocumentTitle) {
						  document.title = 'Mark Bourdillon Photography         : ' + photoCaption;
			    }
        if (op.$detail.length > 0) {
      temp = op.nextPhoto.fnGetImageDetails();
	    op.$detail.fadeGalleryDetails(temp, op.speed, function(){
	    var options = {};	    	      	      resizePhotoInfo(options);
        if (typeof(backgrounds) != 'undefined' && op.nextPhoto == backgrounds[op.nextPhoto.id]) {
  	      toggleAddToCartConfirm(backgrounds);
  	    } else if (typeof(photos) != 'undefined' && op.nextPhoto == photos[op.nextPhoto.id]) {
  	      toggleAddToCartConfirm(photos);
  	    }
	    });
    }
        if (!op.speed) {      clik.doColumnResize(false, op.$photo.add(op.$detail).add(op.$title));    }        
    return html;			}
	else {
				
		window.location = 'photo_' + nextPhoto.id + '.html';
	}
		
}

/***************************************************************************
* Toggle add to cart confirmation element and set up the click event for   *
* the 'Add to cart' button.                                                *
***************************************************************************/
function toggleAddToCartConfirm(array){
  if (typeof(array) !== 'object') {
    array = photos;
  }
	if($('#paymentConfirm').length > 0){
		$('#paymentConfirm').hide();
		$('#paymentAddButton')
		.unbind()
		.click(function(){
						form = document.getElementById('paymentForm');
			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').text('Item added to cart').show();}
				else{
					$('#paymentConfirm').text('Item added to cart').fadeIn();
					dspOrderDetails(form.site.value);
				}
			}
			else{
				$('#paymentConfirm').text('Item not added - check cookies are enabled in your browser.').fadeIn();
			}
		});
	}
}
/***************************************************************************
* Get payment info for image - add as 'method' to photo object             *
***************************************************************************/
photo.prototype.fnGetImageDetails = function(){
	var temp = '';
	if (this.description != '') {
		temp = temp +  '<p id="imageDescription">' + this.description + '</p>';
	}
		if (this.photo_ref != '') {
		temp = temp + '<p class="imageinfo" id="imageRef"><strong>Ref: </strong>' + this.photo_ref + '</p>';
	}
		if (this.takendate != '') {
				
		temp = temp + '<p class="imageinfo" id="imageDate"><strong>Date: </strong>' + this.takendate + '</p>';
	}
	
	if (this.location != '') {
				
		temp = temp + '<p class="imageinfo" id="imageLocation"><strong>Location: </strong>' +  this.location + '</p>';
	}
	
	if (this.photographer != '') {
				
		temp = temp + '<p class="imageinfo" id="imagePhotographer"><strong>Photographer: </strong>' + this.photographer + '</p>';
	}
					
				if (temp != '') {
		temp = temp + '<div class="spacer"></div>';
	}
	return temp;
};

/***************************************************************************
* Get payment info for image - add as 'method' to photo object             *
***************************************************************************/
photo.prototype.fnGetPaymentInfo = function(){
	var temp = '';
	if (this.item_price !== '') {
				temp = temp + '<p>Order this print:</p>';
				temp = temp + '<p class="imageinfo" id="imagePrice"><strong>' + this.purchase_instruction + '</strong> 							' + (this.item_price).toFixed(2) + '</p>';
		var item_name  = this.purchase_instruction;
		var amount = (this.item_price).toFixed(2);
		var item_option  = 0;
	}
	else if (this.payment_groups_id !== '') {
		temp = temp + '<p>Buy this print online:</p>';
				temp = temp + '<form id="paymentOptions" style="margin:0px;border:0px;" name="paymentOptions">';
											temp = temp + '<select class="paymentlink" name="payment_options_id" onchange="updateItemValues(document.forms.paymentForm,this.form.payment_options_id.options[this.form.payment_options_id.options.selectedIndex].value);">';
				
		temp = temp + getPaymentOptions(this.payment_groups_id);
		temp = temp + '</select>';
		temp = 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 = 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({            href: thumbnails[imageID].fnGalleryLink(gallery_id),            title: galleries[gallery_id].title          });
        }
							}
										}
}

/***************************************************************************
* 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 + ' | ';
				}
				temp = temp + '<a href="' + galleries[i].section_code + '_' + galleries[i].id + '.html">' + galleries[i].title + '</a>';
			}
		}
		document.all.galleryLinks.innerHTML = 'Other galleries: ' + temp;
	}
}

		

