window.thumbnails = {};
															thumbnails[1665394] = clik.newPhoto({"id":1665394,"src":"Trusthorpe-chalets_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":130,"caption":"","height":84});
															thumbnails[1665708] = clik.newPhoto({"id":1665708,"src":"Donna-Nook-White-1_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":130,"caption":"","height":85});
															thumbnails[1665739] = clik.newPhoto({"id":1665739,"src":"Belton-house-snow2_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":130,"caption":"","height":84});
															thumbnails[3384180] = clik.newPhoto({"id":3384180,"src":"map1_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":117,"caption":"","height":130});
															thumbnails[7441448] = clik.newPhoto({"id":7441448,"src":"MarCamGranMus_8509web1_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":130,"caption":"","height":87});
															thumbnails[7650325] = clik.newPhoto({"id":7650325,"src":"MCatSamScorerInt_8935_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":130,"caption":"","height":84});
															thumbnails[7650715] = clik.newPhoto({"id":7650715,"src":"MCatSamScorerInt_8923_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":130,"caption":"","height":87});
															thumbnails[7653480] = clik.newPhoto({"id":7653480,"src":"Ribbon_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":130,"caption":"","height":86});
															thumbnails[7658005] = clik.newPhoto({"id":7658005,"src":"MCatSamScorer1_5F3E50C1-1EC9-D45B-1C63D934D019D828_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":110,"caption":"","height":130});
															thumbnails[1662947] = clik.newPhoto({"id":1662947,"src":"Wroclaw-statues-1-rvp_thumb.jpg","galleries_id":112247,"server_id":1,"link":"photo_1662947.html","width":130,"caption":"","height":87});
															thumbnails[1665323] = clik.newPhoto({"id":1665323,"src":"Belton-House-290106_thumb.jpg","galleries_id":112357,"server_id":1,"link":"photo_1665323.html","width":130,"caption":"","height":85});
															thumbnails[1665453] = clik.newPhoto({"id":1665453,"src":"Beach-Hut-Painter_thumb.jpg","galleries_id":112239,"server_id":1,"link":"photo_1665453.html","width":85,"caption":"","height":130});
															thumbnails[1665694] = clik.newPhoto({"id":1665694,"src":"Donna-Nook-Orange-2_thumb.jpg","galleries_id":112375,"server_id":1,"link":"photo_1665694.html","width":130,"caption":"","height":84});
															thumbnails[7653450] = clik.newPhoto({"id":7653450,"src":"Belton_Park_Bench_thumb.jpg","galleries_id":414959,"server_id":1,"link":"photo_7653450.html","width":130,"caption":"","height":87});
															thumbnails[1663021] = clik.newPhoto({"id":1663021,"src":"Mablethorpe-Beach-Huts_thumb.jpg","galleries_id":112247,"server_id":1,"link":"photo_1663021.html","width":130,"caption":"","height":85});
															thumbnails[1665455] = clik.newPhoto({"id":1665455,"src":"Coney-Island-Big-Man_thumb.jpg","galleries_id":112239,"server_id":1,"link":"photo_1665455.html","width":83,"caption":"","height":130});
															thumbnails[1665707] = clik.newPhoto({"id":1665707,"src":"Donna-Nook-Target-3_thumb.jpg","galleries_id":112375,"server_id":1,"link":"photo_1665707.html","width":130,"caption":"","height":84});
															thumbnails[1665742] = clik.newPhoto({"id":1665742,"src":"Belton-house-wide_thumb.jpg","galleries_id":112357,"server_id":1,"link":"photo_1665742.html","width":130,"caption":"","height":81});
															thumbnails[7653453] = clik.newPhoto({"id":7653453,"src":"EyesWideShut_thumb.jpg","galleries_id":414959,"server_id":1,"link":"photo_7653453.html","width":130,"caption":"","height":87});
															thumbnails[1664093] = clik.newPhoto({"id":1664093,"src":"Namibia-speed-60_thumb.jpg","galleries_id":112247,"server_id":1,"link":"photo_1664093.html","width":130,"caption":"","height":85});
															thumbnails[1665458] = clik.newPhoto({"id":1665458,"src":"Katie-Beach_thumb.jpg","galleries_id":112239,"server_id":1,"link":"photo_1665458.html","width":84,"caption":"","height":130});
															thumbnails[1665699] = clik.newPhoto({"id":1665699,"src":"Mablethorpe-Beach-Huts1_thumb.jpg","galleries_id":112375,"server_id":1,"link":"photo_1665699.html","width":130,"caption":"","height":85});
															thumbnails[1665736] = clik.newPhoto({"id":1665736,"src":"Belton-gate-snow_thumb.jpg","galleries_id":112357,"server_id":1,"link":"photo_1665736.html","width":130,"caption":"","height":85});
															thumbnails[7653464] = clik.newPhoto({"id":7653464,"src":"Window-Alcatraz_thumb.jpg","galleries_id":414959,"server_id":1,"link":"photo_7653464.html","width":130,"caption":"","height":87});
															thumbnails[1664100] = clik.newPhoto({"id":1664100,"src":"Coney-Island-School-Bus_thumb.jpg","galleries_id":112247,"server_id":1,"link":"photo_1664100.html","width":130,"caption":"","height":80});
															thumbnails[1665324] = clik.newPhoto({"id":1665324,"src":"Belton-House-dogs_thumb.jpg","galleries_id":112357,"server_id":1,"link":"photo_1665324.html","width":130,"caption":"","height":84});
															thumbnails[1665702] = clik.newPhoto({"id":1665702,"src":"Donna-Nook-Orange-3_thumb.jpg","galleries_id":112375,"server_id":1,"link":"photo_1665702.html","width":130,"caption":"","height":83});
															thumbnails[7653458] = clik.newPhoto({"id":7653458,"src":"Sydney-Opera-House-Roof_thumb.jpg","galleries_id":414959,"server_id":1,"link":"photo_7653458.html","width":130,"caption":"","height":87});
															thumbnails[7653563] = clik.newPhoto({"id":7653563,"src":"Matches_thumb.jpg","galleries_id":112239,"server_id":1,"link":"photo_7653563.html","width":85,"caption":"","height":130});
															thumbnails[1663137] = clik.newPhoto({"id":1663137,"src":"Ladies-on-Bench_thumb.jpg","galleries_id":112247,"server_id":1,"link":"photo_1663137.html","width":130,"caption":"","height":85});
															thumbnails[1665465] = clik.newPhoto({"id":1665465,"src":"Dermot-at-Belton-cropped_thumb.jpg","galleries_id":112239,"server_id":1,"link":"photo_1665465.html","width":89,"caption":"","height":130});
															thumbnails[1672151] = clik.newPhoto({"id":1672151,"src":"Belton-Arch_thumb.jpg","galleries_id":112357,"server_id":1,"link":"photo_1672151.html","width":84,"caption":"","height":130});
															thumbnails[3047304] = clik.newPhoto({"id":3047304,"src":"Trusthorpe-Seat-Pods_thumb.jpg","galleries_id":112375,"server_id":1,"link":"photo_3047304.html","width":130,"caption":"","height":85});
															thumbnails[7653454] = clik.newPhoto({"id":7653454,"src":"Luna-Park-Ferris-Wheel_thumb.jpg","galleries_id":414959,"server_id":1,"link":"photo_7653454.html","width":130,"caption":"","height":85});
															thumbnails[7653472] = clik.newPhoto({"id":7653472,"src":"Ruby_thumb.jpg","galleries_id":414959,"server_id":1,"link":"photo_7653472.html","width":130,"caption":"","height":112});
															thumbnails[1665236] = clik.newPhoto({"id":1665236,"src":"Guggenheim-Lobby_thumb.jpg","galleries_id":112247,"server_id":1,"link":"photo_1665236.html","width":130,"caption":"","height":81});
															thumbnails[1665467] = clik.newPhoto({"id":1665467,"src":"Spitzkopf-jagged-rock-moon_thumb.jpg","galleries_id":112239,"server_id":1,"link":"photo_1665467.html","width":85,"caption":"","height":130});
															thumbnails[1672161] = clik.newPhoto({"id":1672161,"src":"Belton-clock-215_thumb.jpg","galleries_id":112357,"server_id":1,"link":"photo_1672161.html","width":86,"caption":"","height":130});
															thumbnails[3047306] = clik.newPhoto({"id":3047306,"src":"Mablethorpe-Deck-Chairs-200_thumb.jpg","galleries_id":112375,"server_id":1,"link":"photo_3047306.html","width":130,"caption":"","height":86});
															thumbnails[1665308] = clik.newPhoto({"id":1665308,"src":"Moody3_thumb.jpg","galleries_id":112247,"server_id":1,"link":"photo_1665308.html","width":130,"caption":"","height":85});
															thumbnails[1665461] = clik.newPhoto({"id":1665461,"src":"Spitzkopf-Arch_thumb.jpg","galleries_id":112239,"server_id":1,"link":"photo_1665461.html","width":85,"caption":"","height":130});
															thumbnails[1665709] = clik.newPhoto({"id":1665709,"src":"Donna-Nook-White-2_thumb.jpg","galleries_id":112375,"server_id":1,"link":"photo_1665709.html","width":130,"caption":"","height":85});
															thumbnails[1672162] = clik.newPhoto({"id":1672162,"src":"Belton-House-roof_thumb.jpg","galleries_id":112357,"server_id":1,"link":"photo_1672162.html","width":85,"caption":"","height":130});
															thumbnails[7653474] = clik.newPhoto({"id":7653474,"src":"Harold_and_hisTruck_thumb.jpg","galleries_id":414959,"server_id":1,"link":"photo_7653474.html","width":130,"caption":"","height":88});
															thumbnails[1665316] = clik.newPhoto({"id":1665316,"src":"Coney-Island-Burger-Lady_thumb.jpg","galleries_id":112247,"server_id":1,"link":"photo_1665316.html","width":130,"caption":"","height":88});
															thumbnails[1665470] = clik.newPhoto({"id":1665470,"src":"Venice-Gondala-1-rvp_thumb.jpg","galleries_id":112239,"server_id":1,"link":"photo_1665470.html","width":85,"caption":"","height":130});
															thumbnails[1665712] = clik.newPhoto({"id":1665712,"src":"Trusthorpe-chalets1_thumb.jpg","galleries_id":112375,"server_id":1,"link":"photo_1665712.html","width":130,"caption":"","height":84});
															thumbnails[1672163] = clik.newPhoto({"id":1672163,"src":"Belton-House-Gate_thumb.jpg","galleries_id":112357,"server_id":1,"link":"photo_1672163.html","width":84,"caption":"","height":130});
															thumbnails[7653746] = clik.newPhoto({"id":7653746,"src":"WoolloomoolooSunset_thumb.jpg","galleries_id":414959,"server_id":1,"link":"photo_7653746.html","width":130,"caption":"","height":85});
															thumbnails[1665382] = clik.newPhoto({"id":1665382,"src":"Casa-batllo-chimneys1_thumb.jpg","galleries_id":112247,"server_id":1,"link":"photo_1665382.html","width":130,"caption":"","height":85});
															thumbnails[3047307] = clik.newPhoto({"id":3047307,"src":"Donna-nook-family-2_thumb.jpg","galleries_id":112375,"server_id":1,"link":"photo_3047307.html","width":130,"caption":"","height":80});
															thumbnails[3047328] = clik.newPhoto({"id":3047328,"src":"belton-garden-urn-160C_thumb.jpg","galleries_id":112357,"server_id":1,"link":"photo_3047328.html","width":84,"caption":"","height":130});
															thumbnails[7653465] = clik.newPhoto({"id":7653465,"src":"Elgol_thumb.jpg","galleries_id":414959,"server_id":1,"link":"photo_7653465.html","width":130,"caption":"","height":87});
															thumbnails[7653502] = clik.newPhoto({"id":7653502,"src":"LincolnCathedralCeilingCropped_thumb.jpg","galleries_id":112239,"server_id":1,"link":"photo_7653502.html","width":85,"caption":"","height":130});
															thumbnails[1665392] = clik.newPhoto({"id":1665392,"src":"Seafood-Shellfish_thumb.jpg","galleries_id":112247,"server_id":1,"link":"photo_1665392.html","width":130,"caption":"","height":84});
															thumbnails[1665469] = clik.newPhoto({"id":1665469,"src":"Tree-Jacobs-Ladder_thumb.jpg","galleries_id":112239,"server_id":1,"link":"photo_1665469.html","width":85,"caption":"","height":130});
															thumbnails[1665700] = clik.newPhoto({"id":1665700,"src":"Donna-Nook-Pool-1_thumb.jpg","galleries_id":112375,"server_id":1,"link":"photo_1665700.html","width":130,"caption":"","height":85});
															thumbnails[1672165] = clik.newPhoto({"id":1672165,"src":"Belton-Church_thumb.jpg","galleries_id":112357,"server_id":1,"link":"photo_1672165.html","width":84,"caption":"","height":130});
															thumbnails[7653457] = clik.newPhoto({"id":7653457,"src":"Sydney-Harbour-Bridge-Dusk_thumb.jpg","galleries_id":414959,"server_id":1,"link":"photo_7653457.html","width":130,"caption":"","height":48});
															thumbnails[1665404] = clik.newPhoto({"id":1665404,"src":"Spitzkopf-lava1_thumb.jpg","galleries_id":112247,"server_id":1,"link":"photo_1665404.html","width":130,"caption":"","height":88});
															thumbnails[1665704] = clik.newPhoto({"id":1665704,"src":"Donna-Nook-Target-1_thumb.jpg","galleries_id":112375,"server_id":1,"link":"photo_1665704.html","width":130,"caption":"","height":85});
															thumbnails[1672167] = clik.newPhoto({"id":1672167,"src":"Belton-weather-vane_thumb.jpg","galleries_id":112357,"server_id":1,"link":"photo_1672167.html","width":85,"caption":"","height":130});
															thumbnails[7653448] = clik.newPhoto({"id":7653448,"src":"African_boys_thumb.jpg","galleries_id":414959,"server_id":1,"link":"photo_7653448.html","width":130,"caption":"","height":85});
															thumbnails[7653560] = clik.newPhoto({"id":7653560,"src":"NoSwimming_thumb.jpg","galleries_id":112239,"server_id":1,"link":"photo_7653560.html","width":85,"caption":"","height":130});
															thumbnails[1665434] = clik.newPhoto({"id":1665434,"src":"Keep-Out_thumb.jpg","galleries_id":112247,"server_id":1,"link":"photo_1665434.html","width":130,"caption":"","height":84});
															thumbnails[3047308] = clik.newPhoto({"id":3047308,"src":"In-search-of-Albion-2008_09_thumb.jpg","galleries_id":112375,"server_id":1,"link":"photo_3047308.html","width":130,"caption":"","height":86});
															thumbnails[3047326] = clik.newPhoto({"id":3047326,"src":"Bellmount-Lambs-1_thumb.jpg","galleries_id":112357,"server_id":1,"link":"photo_3047326.html","width":83,"caption":"","height":130});
															thumbnails[7653462] = clik.newPhoto({"id":7653462,"src":"UluruTrees_thumb.jpg","galleries_id":414959,"server_id":1,"link":"photo_7653462.html","width":130,"caption":"","height":87});
															thumbnails[7653566] = clik.newPhoto({"id":7653566,"src":"Josephine-and-Dermot_thumb.jpg","galleries_id":112239,"server_id":1,"link":"photo_7653566.html","width":87,"caption":"","height":130});
															thumbnails[1665433] = clik.newPhoto({"id":1665433,"src":"Married-Couple-Poland_thumb.jpg","galleries_id":112247,"server_id":1,"link":"photo_1665433.html","width":130,"caption":"","height":86});
															thumbnails[1665471] = clik.newPhoto({"id":1665471,"src":"Warsaw-Palace-2_thumb.jpg","galleries_id":112239,"server_id":1,"link":"photo_1665471.html","width":85,"caption":"","height":130});
															thumbnails[1672169] = clik.newPhoto({"id":1672169,"src":"Belton-House-autumn-2006_thumb.jpg","galleries_id":112357,"server_id":1,"link":"photo_1672169.html","width":130,"caption":"","height":90});
															thumbnails[5133695] = clik.newPhoto({"id":5133695,"src":"Applebys-Ices-van_thumb.jpg","galleries_id":112375,"server_id":1,"link":"photo_5133695.html","width":130,"caption":"","height":86});
															thumbnails[1665376] = clik.newPhoto({"id":1665376,"src":"Warsaw-fountain-reflection_thumb.jpg","galleries_id":112247,"server_id":1,"link":"photo_1665376.html","width":130,"caption":"","height":87});
															thumbnails[1665476] = clik.newPhoto({"id":1665476,"src":"Windsurfer_thumb.jpg","galleries_id":112239,"server_id":1,"link":"photo_1665476.html","width":85,"caption":"","height":130});
															thumbnails[3047312] = clik.newPhoto({"id":3047312,"src":"Belton-fireworks-1_thumb.jpg","galleries_id":112357,"server_id":1,"link":"photo_3047312.html","width":130,"caption":"","height":83});
															thumbnails[5133713] = clik.newPhoto({"id":5133713,"src":"comeupandseeme-1890_thumb.jpg","galleries_id":112375,"server_id":1,"link":"photo_5133713.html","width":87,"caption":"","height":130});
															thumbnails[1665402] = clik.newPhoto({"id":1665402,"src":"Nuns-Icecreaml_thumb.jpg","galleries_id":112247,"server_id":1,"link":"photo_1665402.html","width":130,"caption":"","height":95});
															thumbnails[1665478] = clik.newPhoto({"id":1665478,"src":"Wroclaw-statues-2_thumb.jpg","galleries_id":112239,"server_id":1,"link":"photo_1665478.html","width":88,"caption":"","height":130});
															thumbnails[1665735] = clik.newPhoto({"id":1665735,"src":"belmont-from-grounds1_thumb.jpg","galleries_id":112357,"server_id":1,"link":"photo_1665735.html","width":130,"caption":"","height":85});
															thumbnails[5133715] = clik.newPhoto({"id":5133715,"src":"Mablethorpe-Sharkys-1923_thumb.jpg","galleries_id":112375,"server_id":1,"link":"photo_5133715.html","width":88,"caption":"","height":130});
															thumbnails[1665317] = clik.newPhoto({"id":1665317,"src":"Coney-Island-Burger-Man_thumb.jpg","galleries_id":112247,"server_id":1,"link":"photo_1665317.html","width":130,"caption":"","height":66});
															thumbnails[1665459] = clik.newPhoto({"id":1665459,"src":"Krakow-spiral-stairs_thumb.jpg","galleries_id":112239,"server_id":1,"link":"photo_1665459.html","width":84,"caption":"","height":130});
															thumbnails[3047314] = clik.newPhoto({"id":3047314,"src":"Spitfire-Prom-2008-4952_thumb.jpg","galleries_id":112357,"server_id":1,"link":"photo_3047314.html","width":130,"caption":"","height":87});
															thumbnails[5133704] = clik.newPhoto({"id":5133704,"src":"Sutton-Beach-Huts-green_thumb.jpg","galleries_id":112375,"server_id":1,"link":"photo_5133704.html","width":130,"caption":"","height":85});
															thumbnails[1665436] = clik.newPhoto({"id":1665436,"src":"Spitzkopf-jagged-moon-view_thumb.jpg","galleries_id":112247,"server_id":1,"link":"photo_1665436.html","width":130,"caption":"","height":77});
															thumbnails[1665442] = clik.newPhoto({"id":1665442,"src":"Policeman-Grantham-Carnival_thumb.jpg","galleries_id":112247,"server_id":1,"link":"photo_1665442.html","width":130,"caption":"","height":85});
															thumbnails[1665443] = clik.newPhoto({"id":1665443,"src":"Signpost-Walcot1_thumb.jpg","galleries_id":112247,"server_id":1,"link":"photo_1665443.html","width":130,"caption":"","height":85});
															thumbnails[1665447] = clik.newPhoto({"id":1665447,"src":"Wroclaw-Railway-station1_thumb.jpg","galleries_id":112247,"server_id":1,"link":"photo_1665447.html","width":130,"caption":"","height":83});
															thumbnails[1665384] = clik.newPhoto({"id":1665384,"src":"casa-batllo-rooftop1_thumb.jpg","galleries_id":112247,"server_id":1,"link":"photo_1665384.html","width":130,"caption":"","height":97});
															thumbnails[1665448] = clik.newPhoto({"id":1665448,"src":"Cape-Town-Sunset-Sky1_thumb.jpg","galleries_id":112247,"server_id":1,"link":"photo_1665448.html","width":130,"caption":"","height":85});
															thumbnails[3050596] = clik.newPhoto({"id":3050596,"src":"Krakow-Pilsudski-Bridge-wal_thumb.jpg","galleries_id":112247,"server_id":1,"link":"photo_3050596.html","width":130,"caption":"","height":85});
															thumbnails[1665380] = clik.newPhoto({"id":1665380,"src":"Guggenheim-Interior1-_thumb.jpg","galleries_id":112247,"server_id":1,"link":"photo_1665380.html","width":130,"caption":"","height":85});

/***************************************************************************
* Create the array of Gallery objects                                      *
***************************************************************************/
var galleries = new Object();
				  						galleries[112247] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"One","link":"gallery_112247.html","maxRecords":0.0,"photoIDs":[1662947.0,1663021.0,1664093.0,1664100.0,1663137.0,1665236.0,1665308.0,1665316.0,1665382.0,1665392.0,1665404.0,1665434.0,1665433.0,1665376.0,1665402.0,1665317.0,1665436.0,1665442.0,1665443.0,1665447.0,1665384.0,1665448.0,3050596.0,1665380.0],"skipIndex":0,"section_code":"gallery","featured_images":1663021.0,"id":112247,"singleSection":false});				  						galleries[112239] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Two","link":"gallery_112239.html","maxRecords":0.0,"photoIDs":[1665453.0,1665455.0,1665458.0,7653563.0,1665465.0,1665467.0,1665461.0,1665470.0,7653502.0,1665469.0,7653560.0,7653566.0,1665471.0,1665476.0,1665478.0,1665459.0],"skipIndex":0,"section_code":"gallery","featured_images":1665478.0,"id":112239,"singleSection":false});				  						galleries[414959] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Three","link":"gallery_414959.html","maxRecords":0.0,"photoIDs":[7653450.0,7653453.0,7653464.0,7653458.0,7653454.0,7653472.0,7653474.0,7653746.0,7653465.0,7653457.0,7653448.0,7653462.0],"skipIndex":0,"section_code":"gallery","featured_images":7653453.0,"id":414959,"singleSection":false});				  						galleries[112357] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Belton House","link":"gallery_112357.html","maxRecords":0.0,"photoIDs":[1665323.0,1665742.0,1665736.0,1665324.0,1672151.0,1672161.0,1672162.0,1672163.0,3047328.0,1672165.0,1672167.0,3047326.0,1672169.0,3047312.0,1665735.0,3047314.0],"skipIndex":0,"section_code":"gallery","featured_images":1665323.0,"id":112357,"singleSection":false});				  						galleries[112375] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Lincolnshire Coast","link":"gallery_112375.html","maxRecords":0.0,"photoIDs":[1665694.0,1665707.0,1665699.0,1665702.0,3047304.0,3047306.0,1665709.0,1665712.0,3047307.0,1665700.0,1665704.0,3047308.0,5133695.0,5133713.0,5133715.0,5133704.0],"skipIndex":0,"section_code":"gallery","featured_images":1665694.0,"id":112375,"singleSection":false});/***************************************************************************
* Create the array of image sets                                           *
***************************************************************************/
var imageSets = {};
imageSets[1] = '7653464,7653462,7653458,7653453,7653450,1662947';
imageSets[2] = '7653453,1665694,1665478,1665323,1663021';
imageSets[3] = '7658005,7653746,7653566,7653563,7653560,7653502,7653480,7653474,7653472,7653465,7653464,7653462,7653458,7653457,7653454,7653453,7653450,7653448,7650715,7650325,7441448,5133715,5133713,5133704,5133695,3384180,3050596,3047328,3047326,3047314,3047312,3047308,3047307,3047306,3047304,1672169,1672167,1672165,1672163,1672162,1672161,1672151,1665742,1665739,1665736,1665735,1665712,1665709,1665708,1665707';
 /***************************************************************************
* Get a server path given an ID                                            *
***************************************************************************/
function getServerPath(server_id) {
	var val = -1;
		switch (server_id) {
		case 51:
		val = 'www12.clikpic.com/martincameron/images';
		break;
	}
		switch (server_id) {
		case 21:
		val = 'http://www6.clikpic.com/martincameron/images';
		break;
	}
		switch (server_id) {
		case 1:
		val = 'http://www1.clikpic.com/martincameron/images';
		break;
	}
		switch (server_id) {
		case 2:
		val = 'http://admin.clikpic.com/martincameron/images';
		break;
	}
		switch (server_id) {
		case 24:
		val = 'http://tpc15/clikpic/martincameron/images';
		break;
	}
		switch (server_id) {
		case 4:
		val = 'http://clikchurch.clikpic.com/martincameron/images';
		break;
	}
		switch (server_id) {
		case 5:
		val = 'http://www2.clikpic.com/martincameron/images';
		break;
	}
		switch (server_id) {
		case 22:
		val = 'http://tpc5/clikpic/martincameron/images';
		break;
	}
		switch (server_id) {
		case 23:
		val = 'http://tpc10/clikpic/martincameron/images';
		break;
	}
		switch (server_id) {
		case 25:
		val = 'http://tpc16/clikpic/martincameron/images';
		break;
	}
		switch (server_id) {
		case 26:
		val = 'http://tpc20/clikpic/martincameron/images';
		break;
	}
		switch (server_id) {
		case 40:
		val = 'http://www11.clikpic.com/martincameron/images';
		break;
	}
		switch (server_id) {
		case 42:
		val = 'db2.clikpic.com/martincameron/images';
		break;
	}
		switch (server_id) {
		case 15:
		val = 'http://www3.clikpic.com/martincameron/images';
		break;
	}
		switch (server_id) {
		case 18:
		val = 'http://www4.clikpic.com/martincameron/images';
		break;
	}
		switch (server_id) {
		case 19:
		val = 'http://www5.clikpic.com/martincameron/images';
		break;
	}
		switch (server_id) {
		case 31:
		val = 'http://www7.clikpic.com/martincameron/images';
		break;
	}
		switch (server_id) {
		case 32:
		val = 'http://www8.clikpic.com/martincameron/images';
		break;
	}
		switch (server_id) {
		case 34:
		val = 'http://www9.clikpic.com/martincameron/images';
		break;
	}
		switch (server_id) {
		case 35:
		val = 'http://admin3.clikpic.com/martincameron/images';
		break;
	}
		switch (server_id) {
		case 37:
		val = 'http://admin4.clikpic.com/martincameron/images';
		break;
	}
		switch (server_id) {
		case 38:
		val = 'http://admin5.clikpic.com/martincameron/images';
		break;
	}
		switch (server_id) {
		case 39:
		val = 'http://www10.clikpic.com/martincameron/images';
		break;
	}
		switch (server_id) {
		case 50:
		val = '[cliktext value=article.servers_id type=servers_id]/martincameron/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:'',$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 = 'MARTIN CAMERON  photographer: ' + 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.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="updateItemValues($(this.form).next(\'#paymentForm\')[0],this.form.payment_options_id.options[this.form.payment_options_id.options.selectedIndex].value);">';
		
		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 += '<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;
	}
}

			

