window.thumbnails = {};
															thumbnails[8738226] = clik.newPhoto({"id":8738226,"src":"f_logo_small_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":30,"caption":"","height":30});
															thumbnails[9105433] = clik.newPhoto({"id":9105433,"src":"Memory_website_1_thumb.jpg","galleries_id":191415,"server_id":37,"link":"photo_9105433.html","width":130,"caption":"Memory","height":130});
															thumbnails[9105448] = clik.newPhoto({"id":9105448,"src":"Roadside_website_1_thumb.jpg","galleries_id":191415,"server_id":37,"link":"photo_9105448.html","width":130,"caption":"Roadside","height":130});
															thumbnails[9105455] = clik.newPhoto({"id":9105455,"src":"Shadow_website_1_thumb.jpg","galleries_id":191415,"server_id":37,"link":"photo_9105455.html","width":130,"caption":"Shadow","height":130});
															thumbnails[9105462] = clik.newPhoto({"id":9105462,"src":"What_is_left_website_1_thumb.jpg","galleries_id":191415,"server_id":37,"link":"photo_9105462.html","width":130,"caption":"What Is Left","height":130});
															thumbnails[8739729] = clik.newPhoto({"id":8739729,"src":"4882_2_website_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_8739729.html","width":130,"caption":"Last Light #1","height":87});
															thumbnails[8738225] = clik.newPhoto({"id":8738225,"src":"4780_website1_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_8738225.html","width":130,"caption":"Reflection #2","height":104});
															thumbnails[8739717] = clik.newPhoto({"id":8739717,"src":"5395_2_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_8739717.html","width":130,"caption":"Last Light #3","height":87});
															thumbnails[8739210] = clik.newPhoto({"id":8739210,"src":"5251_website1_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_8739210.html","width":130,"caption":"Morning Light at Castlerigg Stone Circle #2","height":130});
															thumbnails[8739692] = clik.newPhoto({"id":8739692,"src":"5237_2_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_8739692.html","width":130,"caption":"Last Light #2","height":195});
															thumbnails[8739723] = clik.newPhoto({"id":8739723,"src":"5106_website1_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_8739723.html","width":130,"caption":"Eight","height":163});
															thumbnails[6962885] = clik.newPhoto({"id":6962885,"src":"3317_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_6962885.html","width":130,"caption":"Colours in the Sky","height":69});
															thumbnails[6962876] = clik.newPhoto({"id":6962876,"src":"3343_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_6962876.html","width":130,"caption":"Sunrise over Vale of Evesham","height":69});
															thumbnails[6962890] = clik.newPhoto({"id":6962890,"src":"3283_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_6962890.html","width":130,"caption":"Sky on Fire","height":69});
															thumbnails[6222887] = clik.newPhoto({"id":6222887,"src":"Classic_Wensleydale_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_6222887.html","width":130,"caption":"Wensleydale Barn","height":195});
															thumbnails[1832308] = clik.newPhoto({"id":1832308,"src":"Red_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_1832308.html","width":130,"caption":"Red","height":195});
															thumbnails[6222944] = clik.newPhoto({"id":6222944,"src":"With_the_Flow_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_6222944.html","width":130,"caption":"With the Flow","height":195});
															thumbnails[6222895] = clik.newPhoto({"id":6222895,"src":"2274_First_Light_lr_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_6222895.html","width":130,"caption":"First Light","height":87});
															thumbnails[3671078] = clik.newPhoto({"id":3671078,"src":"Two_Piers_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_3671078.html","width":130,"caption":"Two Piers","height":69});
															thumbnails[3671072] = clik.newPhoto({"id":3671072,"src":"South_Pier_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_3671072.html","width":130,"caption":"East Pier #1","height":87});
															thumbnails[3671010] = clik.newPhoto({"id":3671010,"src":"Sea_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_3671010.html","width":130,"caption":"Sea","height":87});
															thumbnails[6222908] = clik.newPhoto({"id":6222908,"src":"THE_Steps_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_6222908.html","width":130,"caption":"The Steps","height":163});
															thumbnails[3671054] = clik.newPhoto({"id":3671054,"src":"Rock_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_3671054.html","width":130,"caption":"Rock","height":130});
															thumbnails[7498883] = clik.newPhoto({"id":7498883,"src":"16_Wald_2_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_7498883.html","width":130,"caption":"Woodland #2","height":87});
															thumbnails[7823623] = clik.newPhoto({"id":7823623,"src":"Sunrise_Lyme_Regis__thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_7823623.html","width":130,"caption":"Golden Hour","height":87});
															thumbnails[4804061] = clik.newPhoto({"id":4804061,"src":"17_Wald_3_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_4804061.html","width":130,"caption":"Woodland #3","height":87});
															thumbnails[3120779] = clik.newPhoto({"id":3120779,"src":"05 Out of a Rock_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_3120779.html","width":130,"caption":"Three Birds","height":130});
															thumbnails[4804084] = clik.newPhoto({"id":4804084,"src":"80_In_the_Woods_2_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_4804084.html","width":130,"caption":"Woodland #1","height":130});
															thumbnails[3120788] = clik.newPhoto({"id":3120788,"src":"Golden_Leaves_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_3120788.html","width":130,"caption":"Golden Leaves","height":130});
															thumbnails[3120793] = clik.newPhoto({"id":3120793,"src":"15 Cloudscape_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_3120793.html","width":130,"caption":"Cloudscape","height":130});
															thumbnails[1832302] = clik.newPhoto({"id":1832302,"src":"Crummock Water_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_1832302.html","width":130,"caption":"Crummock Water","height":87});
															thumbnails[7823676] = clik.newPhoto({"id":7823676,"src":"Trees_on_Esher_Common_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_7823676.html","width":130,"caption":"Woodland #4","height":104});
															thumbnails[1832341] = clik.newPhoto({"id":1832341,"src":"Reflections_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_1832341.html","width":130,"caption":"Reflection #1","height":87});
															thumbnails[1832281] = clik.newPhoto({"id":1832281,"src":"Calm Morning_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_1832281.html","width":130,"caption":"Calm Morning","height":87});
															thumbnails[1832317] = clik.newPhoto({"id":1832317,"src":"Tree_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_1832317.html","width":130,"caption":"Tree","height":87});
															thumbnails[3120795] = clik.newPhoto({"id":3120795,"src":"20 Autumn Impressions_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_3120795.html","width":130,"caption":"Autumn Impressions","height":130});
															thumbnails[1832336] = clik.newPhoto({"id":1832336,"src":"390 Spot of Colour_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_1832336.html","width":130,"caption":"Spot of Colour","height":130});
															thumbnails[3120821] = clik.newPhoto({"id":3120821,"src":"35_Morning_Light_at_Castlerigg_Stone_Circle_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_3120821.html","width":130,"caption":"Morning Light at Castlerigg Stone Circle #1","height":130});
															thumbnails[6962860] = clik.newPhoto({"id":6962860,"src":"3069_copy_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_6962860.html","width":130,"caption":"Viewpoint","height":69});
															thumbnails[1841541] = clik.newPhoto({"id":1841541,"src":"Sunset 3 - Crete_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_1841541.html","width":130,"caption":"Boat","height":87});
															thumbnails[6222862] = clik.newPhoto({"id":6222862,"src":"Big_and_Small_thumb.jpg","galleries_id":123157,"server_id":1,"link":"photo_6222862.html","width":130,"caption":"Big and Small","height":69});
															thumbnails[1834444] = clik.newPhoto({"id":1834444,"src":"200 Tree and Gate_thumb.jpg","galleries_id":123159,"server_id":1,"link":"photo_1834444.html","width":130,"caption":"Tree and Gate","height":130});
															thumbnails[6223058] = clik.newPhoto({"id":6223058,"src":"Two_Trees_thumb.jpg","galleries_id":123159,"server_id":1,"link":"photo_6223058.html","width":130,"caption":"Two Trees","height":130});
															thumbnails[1834433] = clik.newPhoto({"id":1834433,"src":"220 Storm Cloud_thumb.jpg","galleries_id":123159,"server_id":1,"link":"photo_1834433.html","width":130,"caption":"Tree and Cloud","height":130});
															thumbnails[4804001] = clik.newPhoto({"id":4804001,"src":"50_Water_Power_1_thumb.jpg","galleries_id":123159,"server_id":1,"link":"photo_4804001.html","width":130,"caption":"Water Power #1","height":87});
															thumbnails[3120893] = clik.newPhoto({"id":3120893,"src":"60 Rushing Water_thumb.jpg","galleries_id":123159,"server_id":1,"link":"photo_3120893.html","width":130,"caption":"Water Power #2","height":130});
															thumbnails[6223004] = clik.newPhoto({"id":6223004,"src":"Wave_Power_thumb.jpg","galleries_id":123159,"server_id":1,"link":"photo_6223004.html","width":130,"caption":"Water Power #3","height":87});
															thumbnails[7503798] = clik.newPhoto({"id":7503798,"src":"4134_Bamburgh_lr_thumb.jpg","galleries_id":123159,"server_id":1,"link":"photo_7503798.html","width":130,"caption":"Bamburgh Castle","height":85});
															thumbnails[7503790] = clik.newPhoto({"id":7503790,"src":"3954_copy_thumb.jpg","galleries_id":123159,"server_id":1,"link":"photo_7503790.html","width":130,"caption":"St Oswald's Way","height":87});
															thumbnails[7503719] = clik.newPhoto({"id":7503719,"src":"4221_Dunstanburgh_Castle_lr_thumb.jpg","galleries_id":123159,"server_id":1,"link":"photo_7503719.html","width":130,"caption":"Dunstanburgh Castle","height":84});
															thumbnails[6962879] = clik.newPhoto({"id":6962879,"src":"3391_thumb.jpg","galleries_id":123159,"server_id":1,"link":"photo_6962879.html","width":130,"caption":"Still Standing","height":87});
															thumbnails[6362463] = clik.newPhoto({"id":6362463,"src":"Towards_the_Light_thumb.jpg","galleries_id":123159,"server_id":1,"link":"photo_6362463.html","width":130,"caption":"Towards the Light","height":244});
															thumbnails[4803470] = clik.newPhoto({"id":4803470,"src":"410_Between_A_Rock_and_A_Hard_Place_thumb.jpg","galleries_id":123159,"server_id":1,"link":"photo_4803470.html","width":130,"caption":"Between A Rock and A Hard Place","height":130});
															thumbnails[3120830] = clik.newPhoto({"id":3120830,"src":"200_In_the_Light_thumb.jpg","galleries_id":123159,"server_id":1,"link":"photo_3120830.html","width":130,"caption":"In the Light","height":130});
															thumbnails[1834501] = clik.newPhoto({"id":1834501,"src":"Jetty_thumb.jpg","galleries_id":123159,"server_id":1,"link":"photo_1834501.html","width":130,"caption":"Jetty","height":130});
															thumbnails[3671086] = clik.newPhoto({"id":3671086,"src":"North_Pier_thumb.jpg","galleries_id":123159,"server_id":1,"link":"photo_3671086.html","width":130,"caption":"West Pier","height":130});
															thumbnails[7503713] = clik.newPhoto({"id":7503713,"src":"4110_sf_thumb.jpg","galleries_id":123159,"server_id":1,"link":"photo_7503713.html","width":130,"caption":"By the Sea 1","height":130});
															thumbnails[1834458] = clik.newPhoto({"id":1834458,"src":"White Horse_thumb.jpg","galleries_id":123159,"server_id":1,"link":"photo_1834458.html","width":130,"caption":"White Horse","height":87});
															thumbnails[7503723] = clik.newPhoto({"id":7503723,"src":"4117_sf_thumb.jpg","galleries_id":123159,"server_id":1,"link":"photo_7503723.html","width":130,"caption":"By the Sea 2","height":130});
															thumbnails[6223052] = clik.newPhoto({"id":6223052,"src":"Yellow_and_Green_thumb.jpg","galleries_id":123156,"server_id":1,"link":"photo_6223052.html","width":130,"caption":"Yellow and Green","height":163});
															thumbnails[1834548] = clik.newPhoto({"id":1834548,"src":"Dahlia 'Souvenir'_thumb.jpg","galleries_id":123156,"server_id":1,"link":"photo_1834548.html","width":130,"caption":"Dahlia Study #1","height":195});
															thumbnails[8523494] = clik.newPhoto({"id":8523494,"src":"Black-eyed_Susan_lr_thumb.jpg","galleries_id":123156,"server_id":1,"link":"photo_8523494.html","width":130,"caption":"Black-Eyed Susan","height":163});
															thumbnails[8523588] = clik.newPhoto({"id":8523588,"src":"Dahlia_study_3_thumb.jpg","galleries_id":123156,"server_id":1,"link":"photo_8523588.html","width":130,"caption":"Dahlia study #2","height":104});
															thumbnails[8523559] = clik.newPhoto({"id":8523559,"src":"Dahlia_study_1_thumb.jpg","galleries_id":123156,"server_id":1,"link":"photo_8523559.html","width":130,"caption":"Dahlia study #3","height":104});
															thumbnails[8523763] = clik.newPhoto({"id":8523763,"src":"Dahlia_study_6_thumb.jpg","galleries_id":123156,"server_id":1,"link":"photo_8523763.html","width":130,"caption":"Dahlia study #4","height":104});
															thumbnails[8523684] = clik.newPhoto({"id":8523684,"src":"Dahlia_study_5_thumb.jpg","galleries_id":123156,"server_id":1,"link":"photo_8523684.html","width":130,"caption":"Dahlia study #5","height":87});
															thumbnails[6962853] = clik.newPhoto({"id":6962853,"src":"3044_thumb.jpg","galleries_id":123156,"server_id":1,"link":"photo_6962853.html","width":130,"caption":"Together","height":104});
															thumbnails[1834567] = clik.newPhoto({"id":1834567,"src":"Shell_thumb.jpg","galleries_id":123156,"server_id":1,"link":"photo_1834567.html","width":130,"caption":"Shell","height":87});
															thumbnails[1837620] = clik.newPhoto({"id":1837620,"src":"Glass Wing Butterflies_thumb.jpg","galleries_id":123156,"server_id":1,"link":"photo_1837620.html","width":130,"caption":"Glasswing Butterflies","height":87});
															thumbnails[1847442] = clik.newPhoto({"id":1847442,"src":"400 Busy Bee_thumb.jpg","galleries_id":123156,"server_id":1,"link":"photo_1847442.html","width":130,"caption":"Busy Bee","height":130});
															thumbnails[1837627] = clik.newPhoto({"id":1837627,"src":"Monarch Butterfly_thumb.jpg","galleries_id":123156,"server_id":1,"link":"photo_1837627.html","width":130,"caption":"Monarch Butterfly","height":87});
															thumbnails[1834579] = clik.newPhoto({"id":1834579,"src":"Drops_thumb.jpg","galleries_id":123156,"server_id":1,"link":"photo_1834579.html","width":130,"caption":"Water Droplets","height":87});
															thumbnails[1837628] = clik.newPhoto({"id":1837628,"src":"White Goose_thumb.jpg","galleries_id":123156,"server_id":1,"link":"photo_1837628.html","width":130,"caption":"White Goose","height":87});
															thumbnails[1834626] = clik.newPhoto({"id":1834626,"src":"Harvest_thumb.jpg","galleries_id":123156,"server_id":1,"link":"photo_1834626.html","width":130,"caption":"Harvest","height":87});
															thumbnails[7287691] = clik.newPhoto({"id":7287691,"src":"2910_thumb.jpg","galleries_id":394125,"server_id":1,"link":"photo_7287691.html","width":130,"caption":"Art","height":195});
															thumbnails[7287701] = clik.newPhoto({"id":7287701,"src":"2908_thumb.jpg","galleries_id":394125,"server_id":1,"link":"photo_7287701.html","width":130,"caption":"Leaf","height":195});
															thumbnails[7287712] = clik.newPhoto({"id":7287712,"src":"9825_thumb.jpg","galleries_id":394125,"server_id":1,"link":"photo_7287712.html","width":130,"caption":"Four","height":195});
															thumbnails[7287724] = clik.newPhoto({"id":7287724,"src":"9865_thumb.jpg","galleries_id":394125,"server_id":1,"link":"photo_7287724.html","width":130,"caption":"News","height":87});
															thumbnails[7287726] = clik.newPhoto({"id":7287726,"src":"9867_thumb.jpg","galleries_id":394125,"server_id":1,"link":"photo_7287726.html","width":130,"caption":"Disel","height":87});
															thumbnails[7287731] = clik.newPhoto({"id":7287731,"src":"9918_thumb.jpg","galleries_id":394125,"server_id":1,"link":"photo_7287731.html","width":130,"caption":"Hooked","height":87});
															thumbnails[7287740] = clik.newPhoto({"id":7287740,"src":"9814_thumb.jpg","galleries_id":394125,"server_id":1,"link":"photo_7287740.html","width":130,"caption":"Window","height":130});
															thumbnails[7287742] = clik.newPhoto({"id":7287742,"src":"2924_thumb.jpg","galleries_id":394125,"server_id":1,"link":"photo_7287742.html","width":130,"caption":"Way Out","height":130});
															thumbnails[7287748] = clik.newPhoto({"id":7287748,"src":"9871_thumb.jpg","galleries_id":394125,"server_id":1,"link":"photo_7287748.html","width":130,"caption":"No Way Out","height":130});
															thumbnails[7287752] = clik.newPhoto({"id":7287752,"src":"2899_2_thumb.jpg","galleries_id":394125,"server_id":1,"link":"photo_7287752.html","width":130,"caption":"Ornament","height":100});
															thumbnails[7287759] = clik.newPhoto({"id":7287759,"src":"9894_thumb.jpg","galleries_id":394125,"server_id":1,"link":"photo_7287759.html","width":130,"caption":"Door","height":195});
															thumbnails[7287761] = clik.newPhoto({"id":7287761,"src":"9916_thumb.jpg","galleries_id":394125,"server_id":1,"link":"photo_7287761.html","width":130,"caption":"Instruction","height":87});
															thumbnails[7950191] = clik.newPhoto({"id":7950191,"src":"01_Rush_Hour_thumb.jpg","galleries_id":449804,"server_id":1,"link":"photo_7950191.html","width":130,"caption":"Rush Hour","height":130});
															thumbnails[7950245] = clik.newPhoto({"id":7950245,"src":"02_Up_thumb.jpg","galleries_id":449804,"server_id":1,"link":"photo_7950245.html","width":130,"caption":"Up","height":130});
															thumbnails[7950282] = clik.newPhoto({"id":7950282,"src":"03_Going_Home_thumb.jpg","galleries_id":449804,"server_id":1,"link":"photo_7950282.html","width":130,"caption":"Going Home","height":130});
															thumbnails[7950286] = clik.newPhoto({"id":7950286,"src":"04_Come_Outside_thumb.jpg","galleries_id":449804,"server_id":1,"link":"photo_7950286.html","width":130,"caption":"Come Outside","height":130});
															thumbnails[7950296] = clik.newPhoto({"id":7950296,"src":"05_In_The_Office_thumb.jpg","galleries_id":449804,"server_id":1,"link":"photo_7950296.html","width":130,"caption":"In the Office","height":130});
															thumbnails[7950299] = clik.newPhoto({"id":7950299,"src":"06_Good_Reception_thumb.jpg","galleries_id":449804,"server_id":1,"link":"photo_7950299.html","width":130,"caption":"Good Reception","height":130});
															thumbnails[7950310] = clik.newPhoto({"id":7950310,"src":"07_Snap_thumb.jpg","galleries_id":449804,"server_id":1,"link":"photo_7950310.html","width":130,"caption":"Snap!","height":130});
															thumbnails[7950319] = clik.newPhoto({"id":7950319,"src":"08_Flower_Power_thumb.jpg","galleries_id":449804,"server_id":1,"link":"photo_7950319.html","width":130,"caption":"Flower Power","height":130});
															thumbnails[7950341] = clik.newPhoto({"id":7950341,"src":"09_Statement_thumb.jpg","galleries_id":449804,"server_id":1,"link":"photo_7950341.html","width":130,"caption":"Statement","height":130});
															thumbnails[7950349] = clik.newPhoto({"id":7950349,"src":"10_Waiting1...1_thumb.jpg","galleries_id":449804,"server_id":1,"link":"photo_7950349.html","width":130,"caption":"Waiting #1","height":130});
															thumbnails[7950373] = clik.newPhoto({"id":7950373,"src":"11_Waiting_2_thumb.jpg","galleries_id":449804,"server_id":1,"link":"photo_7950373.html","width":130,"caption":"Waiting #2","height":130});
															thumbnails[7950389] = clik.newPhoto({"id":7950389,"src":"12_Waiting...3_thumb.jpg","galleries_id":449804,"server_id":1,"link":"photo_7950389.html","width":130,"caption":"Waiting #3","height":130});
															thumbnails[7778007] = clik.newPhoto({"id":7778007,"src":"website_9246_bw_thumb.jpg","galleries_id":414958,"server_id":1,"link":"photo_7778007.html","width":130,"caption":"Into The Unknown","height":69});
															thumbnails[8675301] = clik.newPhoto({"id":8675301,"src":"website_East_Pier_2_thumb.jpg","galleries_id":414958,"server_id":1,"link":"photo_8675301.html","width":130,"caption":"East Pier #2","height":69});
															thumbnails[7778011] = clik.newPhoto({"id":7778011,"src":"website_Eileen_Donan_Castle_thumb.jpg","galleries_id":414958,"server_id":1,"link":"photo_7778011.html","width":130,"caption":"Eileen Donan Castle","height":69});
															thumbnails[7836212] = clik.newPhoto({"id":7836212,"src":"website_Bodiam_Castle_thumb.jpg","galleries_id":414958,"server_id":1,"link":"photo_7836212.html","width":130,"caption":"Bodiam Castle","height":87});
															thumbnails[8675346] = clik.newPhoto({"id":8675346,"src":"website_Tree_thumb.jpg","galleries_id":414958,"server_id":1,"link":"photo_8675346.html","width":130,"caption":"Tree #2","height":87});

/***************************************************************************
* Create the array of Gallery objects                                      *
***************************************************************************/
var galleries = new Object();
				  						galleries[191415] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"New Images","link":"gallery_191415.html","maxRecords":0.0,"photoIDs":[9105433.0,9105448.0,9105455.0,9105462.0],"skipIndex":0,"section_code":"gallery","featured_images":9105433.0,"id":191415,"singleSection":false});				  						galleries[123157] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Colours","link":"gallery_123157.html","maxRecords":0.0,"photoIDs":[8739729.0,8738225.0,8739717.0,8739210.0,8739692.0,8739723.0,6962885.0,6962876.0,6962890.0,6222887.0,1832308.0,6222944.0,6222895.0,3671078.0,3671072.0,3671010.0,6222908.0,3671054.0,7498883.0,7823623.0,4804061.0,3120779.0,4804084.0,3120788.0,3120793.0,1832302.0,7823676.0,1832341.0,1832281.0,1832317.0,3120795.0,1832336.0,3120821.0,6962860.0,1841541.0,6222862.0],"skipIndex":0,"section_code":"gallery","featured_images":4804061.0,"id":123157,"singleSection":false});				  						galleries[123159] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Monochrome Views","link":"gallery_123159.html","maxRecords":0.0,"photoIDs":[1834444.0,6223058.0,1834433.0,4804001.0,3120893.0,6223004.0,7503798.0,7503790.0,7503719.0,6962879.0,6362463.0,4803470.0,3120830.0,1834501.0,3671086.0,7503713.0,1834458.0,7503723.0],"skipIndex":0,"section_code":"gallery","featured_images":4803470.0,"id":123159,"singleSection":false});				  						galleries[123156] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"A Closer Look","link":"gallery_123156.html","maxRecords":0.0,"photoIDs":[6223052.0,1834548.0,8523494.0,8523588.0,8523559.0,8523763.0,8523684.0,6962853.0,1834567.0,1837620.0,1847442.0,1837627.0,1834579.0,1837628.0,1834626.0],"skipIndex":0,"section_code":"gallery","featured_images":"8523763,8523588,1834626","id":123156,"singleSection":false});				  						galleries[414958] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Contrasts","link":"gallery_414958.html","maxRecords":0.0,"photoIDs":[7778007.0,8675301.0,7778011.0,7836212.0,8675346.0],"skipIndex":0,"section_code":"gallery","featured_images":8675301.0,"id":414958,"singleSection":false});				  						galleries[394010] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Places","link":"gallery_394010.html","maxRecords":0.0,"photoIDs":[],"skipIndex":0,"section_code":"gallery","featured_images":"7950191,7287742","id":394010,"singleSection":false});				  						galleries[449804] = clik.newGallery({"parentGallery":394010,"usePopups":false,"title":"London","link":"gallery_449804.html","maxRecords":0.0,"photoIDs":[7950191.0,7950245.0,7950282.0,7950286.0,7950296.0,7950299.0,7950310.0,7950319.0,7950341.0,7950349.0,7950373.0,7950389.0],"skipIndex":0,"section_code":"gallery","featured_images":7950191.0,"id":449804,"singleSection":false});				  						galleries[394125] = clik.newGallery({"parentGallery":394010,"usePopups":false,"title":"Halle, Saale","link":"gallery_394125.html","maxRecords":0.0,"photoIDs":[7287691.0,7287701.0,7287712.0,7287724.0,7287726.0,7287731.0,7287740.0,7287742.0,7287748.0,7287752.0,7287759.0,7287761.0],"skipIndex":0,"section_code":"gallery","featured_images":7287742.0,"id":394125,"singleSection":false});/***************************************************************************
* Create the array of image sets                                           *
***************************************************************************/
var imageSets = {};
imageSets[1] = '9105455';
imageSets[2] = '9105433,4804061,4803470,8523588,8523763,1834626,7287742,7950191,8675301';
imageSets[3] = '3671072,1832341';
 /***************************************************************************
* Get a server path given an ID                                            *
***************************************************************************/
function getServerPath(server_id) {
	var val = -1;
		switch (server_id) {
		case 51:
		val = 'http://www12.clikpic.com/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 0:
		val = 'http://www.clikpic.com/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 1:
		val = 'http://www1.clikpic.com/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 2:
		val = 'http://admin.clikpic.com/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 24:
		val = 'http://tpc15/clikpic/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 4:
		val = 'http://clikchurch.clikpic.com/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 5:
		val = 'http://www2.clikpic.com/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 22:
		val = 'http://tpc5/clikpic/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 23:
		val = 'http://tpc10/clikpic/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 25:
		val = 'http://tpc16/clikpic/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 26:
		val = 'http://tpc20/clikpic/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 40:
		val = 'http://www11.clikpic.com/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 42:
		val = 'db2.clikpic.com/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 15:
		val = 'http://www3.clikpic.com/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 18:
		val = 'http://www4.clikpic.com/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 19:
		val = 'http://www5.clikpic.com/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 31:
		val = 'http://www7.clikpic.com/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 32:
		val = 'http://www8.clikpic.com/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 34:
		val = 'http://www9.clikpic.com/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 35:
		val = 'http://admin3.clikpic.com/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 37:
		val = 'http://admin4.clikpic.com/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 38:
		val = 'http://admin5.clikpic.com/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 39:
		val = 'http://www10.clikpic.com/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 53:
		val = 'http://images.clikpic.com/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 52:
		val = 'http://tpc22/clikpic/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 21:
		val = 'http://www6.clikpic.com/mcgechan/images';
		break;
	}
		switch (server_id) {
		case 50:
		val = '[cliktext value=article.servers_id type=servers_id]/mcgechan/images';
		break;
	}
		return val;
}

/***************************************************************************
* img = reference to image object in which to show image                   *
***************************************************************************/
function showHomeImage(img) {
	imageID = randomListVal('');
	if (!basic) {
		img.src = photos[imageID].src;
		img.width = photos[imageID].width;
		img.height = photos[imageID].height;
		img.parentNode.title = img.alt = photos[imageID].caption;
	} else {
		newImage = new Image(photos[imageID].width,photos[imageID].height);
		newImage.src = photos[imageID].src;
		document.images[img.name] = newImage;
		
	}
}

function getHomeImageLink(imageID) {
  	var href='', photo = (backgrounds || photos || {})[imageID];
	if(photo){
		if (photo && photo.galleries_id != '') {
  			href = photo.fnGalleryLink();
  		}
  		  		else {
  				href += 'gallery.html';
  	  		}
	}
    return href;
}

/***************************************************************************
* Show a random image on home page from featured images                    *
***************************************************************************/
function showHomeImageInline(el, image_sets_id, href) {
	
	var css = {}, imageID,
	    imageSetsId = 1;
	if(image_sets_id){
		imageSetsId = image_sets_id;
	}
	imageID = randomListVal(imageSets[imageSetsId]);
	if (href == null && 'gallery' != '') {
					href = getHomeImageLink(imageID);
	}
	
	updateImage({nextPhoto: backgrounds[imageID], img:el.find('img')[0],
                $photo:el, $title:$('#homeimageTitleContainer'), $detail:$('#homeimageDetailsContainer'),                speed:0, href:href, css:css, onAfter: function(){                  this.closest('.contentsection').doManualAlign({				    inner: 'img',				    crop: 'a'				  });                }              });
}

/***************************************************************************
* Set 'img' to be a new image given its photo() object                     *
***************************************************************************/
function updateImage (options) {
	var defaults = {nextPhoto:'',field:'',img:'',$photo:'',$title:'',$detail:'',$detailContainer:'',
                    updateDocumentTitle:false,speed:0,href:false,css:false,updateHash:false,onAfter:null,onBefore:null},
		op = $.extend({},defaults,options),
		html = '', temp = '',
		photoId = op.nextPhoto.id,
		photoCaption = ''+op.nextPhoto.caption,
		photoSrc = op.nextPhoto.src;
	
	if (op.updateHash && clik.getIDInUrl(location.href,'photo') != op.nextPhoto.id) {
		clik.changeHash('photos_id=' + op.nextPhoto.id, true);
	}
		
	    if (op.$title.length > 0) {
  		op.$title.fadeGalleryDetails(photoCaption, op.speed);
    }
        if (op.updateDocumentTitle) {
						  document.title = 'Astrid McGechan Photography: ' + photoCaption;
			    }
        if (op.$detail.length > 0) {
      	temp = op.nextPhoto.fnGetImageDetails();
	    op.$detail.fadeGalleryDetails(temp, op.speed, function(){
			if (typeof(backgrounds) != 'undefined' && op.nextPhoto == backgrounds[op.nextPhoto.id]) {
				toggleAddToCartConfirm(backgrounds, op.$detail);
			} else if (typeof(photos) != 'undefined' && op.nextPhoto == photos[op.nextPhoto.id]) {
				toggleAddToCartConfirm(photos, op.$detail);
			}
			$('body').trigger('clikUpdate.popup');
	    });
    }
        $(op.$detailContainer).find('.replaceable[class*=replaceable_photo-]').each(function(){
    	var field = clik.getPrefixedClass(this.className, 'replaceable_photo-');
    	if (field in op.nextPhoto) {
    		$(this).fadeGalleryDetails(op.nextPhoto[field], op.speed);
    	}
    }).end().find('.replaceable.photoPayment').fadeGalleryDetails(op.nextPhoto.fnGetPaymentInfo(), op.speed, function(){
		if (typeof(backgrounds) != 'undefined' && op.nextPhoto == backgrounds[op.nextPhoto.id]) {
			toggleAddToCartConfirm(backgrounds, op.$detailContainer);
		} else if (typeof(photos) != 'undefined' && op.nextPhoto == photos[op.nextPhoto.id]) {
			toggleAddToCartConfirm(photos, op.$detailContainer);
		}
		$('body').trigger('clikUpdate.popup');
	});
		if (op.$photo.length > 0) {
		html = $('<img/>',{
			'class': 'mainphoto photo',
			src: photoSrc,
			id: 'mainPic',
			name: 'mainPic',
			width: op.nextPhoto.width,
			height: op.nextPhoto.height,
			alt: photoCaption,
			css: op.css || {}
		});
		if (op.href) {
			if (op.href.match(/<a/)) {
				html = $(op.href).append(html);
			} else {
				html = $('<a/>', {
					href: op.href,
					title: photoCaption
				}).append(html);
			}
		} else {
			html = $('<a/>', {
				title: photoCaption
			}).append(html);
		}
		if (op.speed == 0) {			op.$photo.html(html);			if (op.onBefore) {			  	op.onBefore.apply(op.$photo);			}			if (op.onAfter) {			  	op.onAfter.apply(op.$photo);			}		} else {			op.$photo.stop(true,true).fadeReplaceWith(html,op.speed,'',function(){  				if (op.onAfter) {				  	op.onAfter.apply(this);				}				clik.doColumnResize(false, $(this).add(op.$detail).add(op.$title));			}, op.onBefore);
		}	}
    if (op.field) {
		op.field.value = photoId;
	} else {
		op.$photo.data('image_id', photoId);
    }
        if (!op.speed) {
      	clik.doColumnResize(false, op.$photo.add(op.$detail).add(op.$title));
    }
        
    return html;
	}

/***************************************************************************
* Toggle add to cart confirmation element and set up the click event for   *
* the 'Add to cart' button.                                                *
***************************************************************************/
function toggleAddToCartConfirm(array, root){
	if (typeof(array) !== 'object' || array === null) {
	  	array = photos;
	}
	if (!$(root).length) {		root = $('body');	}	if($('#paymentConfirm', root).length > 0){
		$('#paymentConfirm', root).hide();
		$('#paymentAddButton', root)
		.unbind()
		.click(function(){
						form = $('#paymentForm', root)[0];
			option_id = 0;
			if(form.item_option.value){
				option_id = form.item_option.value;
			}
			if(addItemToBasket(form.item_number.value,array,form.site.value,parseInt(form.quantity.value, 10),option_id)){
				if($.browser.msie){$('#paymentConfirm', root).text('Item added to cart').show();}
				else{
					$('#paymentConfirm', root).text('Item added to cart').fadeIn();
					dspOrderDetails(form.site.value);
				}
			}
			else{
				$('#paymentConfirm', root).text('Item not added - check cookies are enabled in your browser.').fadeIn();
			}
		});
	}
}

/***************************************************************************
* Get payment info for image - add as 'method' to photo object             *
***************************************************************************/
clik.photo.fnGetImageDetails = function(){
	var temp = '';
	if (this.description != '') {
		temp +=  '<div id="imageDescription">' + this.description + '</div>';
	}
		if (this.photo_ref != '') {
		temp += '<div class="imageinfo" id="imageRef"><strong>Ref: </strong>' + this.photo_ref + '</div>';
	}
		if (this.takendate != '') {
		
		temp += '<div class="imageinfo" id="imageDate"><strong>Date: </strong>' + this.takendate + '</div>';
	}
	
	if (this.location != '') {
		
		temp += '<div class="imageinfo" id="imageLocation"><strong>Location: </strong>' +  this.location + '</div>';
	}
	
	if (this.photographer != '') {
		
		temp += '<div class="imageinfo" id="imagePhotographer"><strong>Photographer: </strong>' + this.photographer + '</div>';
	}
				
	temp += this.fnGetPaymentInfo();
				if (temp != '') {
		temp += '<div class="spacer"></div>';
	}
	return temp;
};

/***************************************************************************
* Get payment info for image - add as 'method' to photo object             *
***************************************************************************/
clik.photo.fnGetPaymentInfo = function(){
	var temp = '';
	if (this.item_price !== '') {
																		temp += '<p>Buy now using PayPal:</p>';
				temp += '<div class="imageinfo" id="imagePrice"><strong>' + this.purchase_instruction + '</strong> &pound;' + (this.item_price).toFixed(2) + '</div>';
		var item_name  = this.purchase_instruction;
		var amount = (this.item_price).toFixed(2);
		var item_option  = 0;
	}
		else if (this.payment_groups_id !== '') {
		temp += '<p>Buy this print online:</p>';
				temp += '<form id="paymentOptions" style="margin:0px;border:0px;" name="paymentOptions">';
		 									temp += '<select class="paymentlink" name="payment_options_id" onchange="updateCartValue($(this.form).next(\'#paymentForm\')[0],this.form.payment_options_id.options[this.form.payment_options_id.options.selectedIndex].value); if(divShowing(\'paymentConfirm\')){fadeOut(\'paymentConfirm\', 3)};">';
		
		temp += getPaymentOptions(this.payment_groups_id);
		temp += '</select>';
		temp += '</form>';
				var item_option  = paymentGroups[this.payment_groups_id].options[0];
		if(paymentOptions[item_option]){
			var item_name  = paymentOptions[item_option].payment_option;
			var amount =  paymentOptions[item_option].price;
		}
			}
		else {
		
	}
	if (this.item_price !== '' || this.payment_groups_id !== '') {
											temp += '<form id="paymentForm" style="margin:0px;border:0px;" name="paymentForm">';
			temp += '	<input type="hidden" name="item_option" value="' + item_option + '">';
			temp += '	<input type="hidden" name="site" value="MCGECHAN">';
			temp += '	<input type="hidden" name="item_number" value="'+ this.id +'">';
			temp += '	<input type="hidden" name="quantity" value="1">';
						temp += '	<input value="Add to cart" id="paymentAddButton" class="button" onmouseover="this.className=\'buttonHi\'\;" onmouseout="this.className=\'button\'\;" type="Button">';
							temp += '	<input value="View cart" id="paymentViewButton" class="button" onmouseover="this.className=\'buttonHi\';" onmouseout="this.className=\'button\';" type="Button" onclick="javascript:window.location=\'cart.html\'">';
			temp += '</form>';
						temp += '<div class="clearing">&nbsp;</div>';
			temp += '<div id="confirmContainer">';
			temp += '<div id="paymentConfirm">Item added to cart</div>';
			temp += '</div>';
			temp += '<div class="clearing">&nbsp;</div>';
	}
	return temp;};

/***************************************************************************
* Pick a photo at random from the featured images of a gallery.            *
* Gallery_id = id of gallery to choose,                                    *
* img = reference to html image in                                         *
* which to show image                                                      *
***************************************************************************/
function showGalleryImage(gallery_id, img, updateLink) {
	
	if(img){
		if (location.hash.match('galleries_id=' + gallery_id) && (imageID = location.hash.match('.*photos_id=(.+)$'))) {
		  	imageID = imageID[1];
		} else {
		  	imageID = randomListVal(galleries[gallery_id].featured_images);
		}
		
		if (imageID != 0) {
			img.src = thumbnails[imageID].src;
			img.width = thumbnails[imageID].width;
			img.height = thumbnails[imageID].height;
			img.alt = galleries[gallery_id].title;
			if (updateLink) {
				$(img).parent().attr({					title: galleries[gallery_id].title				}).filter(function(){return this.href;}).attr({					href: thumbnails[imageID].fnGalleryLink(gallery_id)				});
			}
		}
	}
}

/***************************************************************************
* If we have dynamic HTML, replace the galleries link with a list that     *
* doesn't include thecurrent gallery                                       *
***************************************************************************/
function showGalleries(gallery_id) {
		
	
	if (!basic) {
		temp = '';
		for (i = 0; i < galleries.length; i++) {
						
			
			if (galleries[i].id != gallery_id) {
								
				if (temp != '') {
					temp += ' | ';
				}
								temp += '<a href="' + galleries[i].section_code + '_' + galleries[i].id + '.html">' + galleries[i].title + '</a>';
							}
		}
		document.all.galleryLinks.innerHTML = 'Other galleries: ' + temp;
	}
}

			

