window.thumbnails = {};
															thumbnails[1443073] = clik.newPhoto({"id":1443073,"src":"Shop Window_thumb.jpg","galleries_id":"","server_id":18,"link":"#","width":130,"caption":"","height":196});
															thumbnails[8860815] = clik.newPhoto({"id":8860815,"src":"BPF_Logo_thumb.jpg","galleries_id":"","server_id":18,"link":"#","width":130,"caption":"","height":130});
															thumbnails[820785] = clik.newPhoto({"id":820785,"src":"Resize-Wizard-1-Seattle_thumb.jpg","galleries_id":63636,"server_id":18,"link":"photo_820785.html","width":130,"caption":"","height":195});
															thumbnails[820809] = clik.newPhoto({"id":820809,"src":"Resize-Wizard-1-M-Rev_thumb.jpg","galleries_id":63655,"server_id":18,"link":"photo_820809.html","width":130,"caption":"Mercury Rev","height":196});
															thumbnails[820848] = clik.newPhoto({"id":820848,"src":"Resize-Wizard-1-Z19_thumb.jpg","galleries_id":63655,"server_id":18,"link":"photo_820848.html","width":130,"caption":"Zutons","height":196});
															thumbnails[820854] = clik.newPhoto({"id":820854,"src":"Resize-Wizard-1-Z24_thumb.jpg","galleries_id":63655,"server_id":18,"link":"photo_820854.html","width":130,"caption":"Zutons<br>\r\n","height":196});
															thumbnails[820860] = clik.newPhoto({"id":820860,"src":"Resize-Wizard-1-Z72_thumb.jpg","galleries_id":63655,"server_id":18,"link":"photo_820860.html","width":130,"caption":"Zutons<br>\r\n","height":196});
															thumbnails[820866] = clik.newPhoto({"id":820866,"src":"Resize-Wizard-1-T161_thumb.jpg","galleries_id":63655,"server_id":18,"link":"photo_820866.html","width":130,"caption":"Tears - Anderson","height":86});
															thumbnails[820869] = clik.newPhoto({"id":820869,"src":"Resize-Wizard-1-T149_thumb.jpg","galleries_id":63655,"server_id":18,"link":"photo_820869.html","width":130,"caption":"Tears - Butler","height":196});
															thumbnails[1014409] = clik.newPhoto({"id":1014409,"src":"B'rock beach_thumb.jpg","galleries_id":75920,"server_id":18,"link":"photo_1014409.html","width":130,"caption":"","height":86});
															thumbnails[1014410] = clik.newPhoto({"id":1014410,"src":"Carlingford_thumb.jpg","galleries_id":75920,"server_id":18,"link":"photo_1014410.html","width":130,"caption":"","height":98});
															thumbnails[1014411] = clik.newPhoto({"id":1014411,"src":"Yellow-Rope_thumb.jpg","galleries_id":75920,"server_id":18,"link":"photo_1014411.html","width":130,"caption":"","height":98});
															thumbnails[1015101] = clik.newPhoto({"id":1015101,"src":"Sheep_thumb.jpg","galleries_id":75920,"server_id":18,"link":"photo_1015101.html","width":130,"caption":"","height":86});
															thumbnails[1016935] = clik.newPhoto({"id":1016935,"src":"Sunset Ride_thumb.jpg","galleries_id":75920,"server_id":18,"link":"photo_1016935.html","width":130,"caption":"","height":86});
															thumbnails[1017396] = clik.newPhoto({"id":1017396,"src":"BW Heath_thumb.jpg","galleries_id":75920,"server_id":18,"link":"photo_1017396.html","width":130,"caption":"","height":86});
															thumbnails[1017399] = clik.newPhoto({"id":1017399,"src":"Cannon Beach 2_thumb.jpg","galleries_id":75920,"server_id":18,"link":"photo_1017399.html","width":130,"caption":"","height":86});
															thumbnails[1017433] = clik.newPhoto({"id":1017433,"src":"D Orchids_thumb.jpg","galleries_id":76078,"server_id":18,"link":"photo_1017433.html","width":130,"caption":"","height":130});
															thumbnails[1017450] = clik.newPhoto({"id":1017450,"src":"D Ox Cham_thumb.jpg","galleries_id":76078,"server_id":18,"link":"photo_1017450.html","width":130,"caption":"","height":130});
															thumbnails[1017461] = clik.newPhoto({"id":1017461,"src":"Diane Sky_thumb.jpg","galleries_id":76078,"server_id":18,"link":"photo_1017461.html","width":130,"caption":"","height":86});
															thumbnails[1285696] = clik.newPhoto({"id":1285696,"src":"Resize Wizard-Camb BW_thumb.jpg","galleries_id":75920,"server_id":18,"link":"photo_1285696.html","width":130,"caption":"","height":87});
															thumbnails[1443070] = clik.newPhoto({"id":1443070,"src":"Scarf_thumb.jpg","galleries_id":99820,"server_id":18,"link":"photo_1443070.html","width":130,"caption":"","height":104});
															thumbnails[1443072] = clik.newPhoto({"id":1443072,"src":"Scarf2_thumb.jpg","galleries_id":99820,"server_id":18,"link":"photo_1443072.html","width":130,"caption":"","height":104});
															thumbnails[2053941] = clik.newPhoto({"id":2053941,"src":"Resize Wizard-1_1_thumb.jpg","galleries_id":63634,"server_id":18,"link":"photo_2053941.html","width":130,"caption":"Harry","height":182});
															thumbnails[2208930] = clik.newPhoto({"id":2208930,"src":"5280web_thumb.jpg","galleries_id":137233,"server_id":18,"link":"photo_2208930.html","width":130,"caption":"","height":104});
															thumbnails[2208933] = clik.newPhoto({"id":2208933,"src":"5312web_thumb.jpg","galleries_id":137233,"server_id":18,"link":"photo_2208933.html","width":130,"caption":"","height":104});
															thumbnails[2208934] = clik.newPhoto({"id":2208934,"src":"5342web_thumb.jpg","galleries_id":137233,"server_id":18,"link":"photo_2208934.html","width":130,"caption":"","height":104});
															thumbnails[2208936] = clik.newPhoto({"id":2208936,"src":"5318web_thumb.jpg","galleries_id":137233,"server_id":18,"link":"photo_2208936.html","width":130,"caption":"","height":104});
															thumbnails[2208938] = clik.newPhoto({"id":2208938,"src":"5286web_thumb.jpg","galleries_id":137233,"server_id":18,"link":"photo_2208938.html","width":130,"caption":"","height":104});
															thumbnails[2240503] = clik.newPhoto({"id":2240503,"src":"Resize Wizard-1_2_thumb.jpg","galleries_id":158287,"server_id":18,"link":"photo_2240503.html","width":130,"caption":"Matthew","height":195});
															thumbnails[2484467] = clik.newPhoto({"id":2484467,"src":"File0054_thumb.jpg","galleries_id":159458,"server_id":18,"link":"photo_2484467.html","width":130,"caption":"","height":83});
															thumbnails[2484468] = clik.newPhoto({"id":2484468,"src":"File0057_thumb.jpg","galleries_id":159458,"server_id":18,"link":"photo_2484468.html","width":130,"caption":"","height":83});
															thumbnails[2484469] = clik.newPhoto({"id":2484469,"src":"File0063_thumb.jpg","galleries_id":159458,"server_id":18,"link":"photo_2484469.html","width":130,"caption":"","height":83});
															thumbnails[2484470] = clik.newPhoto({"id":2484470,"src":"File0068_thumb.jpg","galleries_id":159458,"server_id":18,"link":"photo_2484470.html","width":130,"caption":"","height":83});
															thumbnails[2484471] = clik.newPhoto({"id":2484471,"src":"File0078_thumb.jpg","galleries_id":159458,"server_id":18,"link":"photo_2484471.html","width":130,"caption":"","height":83});
															thumbnails[2484472] = clik.newPhoto({"id":2484472,"src":"File0080_thumb.jpg","galleries_id":159458,"server_id":18,"link":"photo_2484472.html","width":130,"caption":"","height":83});
															thumbnails[2484473] = clik.newPhoto({"id":2484473,"src":"File0088_thumb.jpg","galleries_id":159458,"server_id":18,"link":"photo_2484473.html","width":130,"caption":"","height":83});
															thumbnails[2484474] = clik.newPhoto({"id":2484474,"src":"File0093_thumb.jpg","galleries_id":159458,"server_id":18,"link":"photo_2484474.html","width":130,"caption":"","height":83});
															thumbnails[2484475] = clik.newPhoto({"id":2484475,"src":"File0102_thumb.jpg","galleries_id":159458,"server_id":18,"link":"photo_2484475.html","width":130,"caption":"","height":88});
															thumbnails[2484476] = clik.newPhoto({"id":2484476,"src":"File0107_thumb.jpg","galleries_id":159458,"server_id":18,"link":"photo_2484476.html","width":130,"caption":"","height":83});
															thumbnails[2484477] = clik.newPhoto({"id":2484477,"src":"File0111_thumb.jpg","galleries_id":159458,"server_id":18,"link":"photo_2484477.html","width":130,"caption":"","height":83});
															thumbnails[3485318] = clik.newPhoto({"id":3485318,"src":"Resize Wizard-1_3_thumb.jpg","galleries_id":75920,"server_id":18,"link":"photo_3485318.html","width":130,"caption":"","height":87});
															thumbnails[3605197] = clik.newPhoto({"id":3605197,"src":"haystack_thumb.jpg","galleries_id":75920,"server_id":18,"link":"photo_3605197.html","width":130,"caption":"In the Shadow of Greatness","height":98});
															thumbnails[3605198] = clik.newPhoto({"id":3605198,"src":"Snow_Field_thumb.jpg","galleries_id":75920,"server_id":18,"link":"photo_3605198.html","width":130,"caption":"Midwinter Snow Tracks","height":98});
															thumbnails[3605201] = clik.newPhoto({"id":3605201,"src":"Surf_thumb.jpg","galleries_id":75920,"server_id":18,"link":"photo_3605201.html","width":130,"caption":"Last Surf before Bed","height":98});
															thumbnails[3832323] = clik.newPhoto({"id":3832323,"src":"Houghton_Stain_Glass_thumb.jpg","galleries_id":63636,"server_id":18,"link":"photo_3832323.html","width":130,"caption":"","height":210});
															thumbnails[1274698] = clik.newPhoto({"id":1274698,"src":"Resize Wizard-11_thumb.jpg","galleries_id":70799,"server_id":18,"link":"photo_1274698.html","width":130,"caption":"","height":194});
															thumbnails[1274701] = clik.newPhoto({"id":1274701,"src":"Resize Wizard-15_thumb.jpg","galleries_id":70799,"server_id":18,"link":"photo_1274701.html","width":130,"caption":"","height":194});
															thumbnails[1290670] = clik.newPhoto({"id":1290670,"src":"Exb-Flyer-low_thumb.jpg","galleries_id":76077,"server_id":18,"link":"photo_1290670.html","width":130,"caption":"Invite to Change & Renewal Exhibition","height":93});
															thumbnails[1274709] = clik.newPhoto({"id":1274709,"src":"Kiss_thumb.jpg","galleries_id":70799,"server_id":18,"link":"photo_1274709.html","width":130,"caption":"","height":195});
															thumbnails[820645] = clik.newPhoto({"id":820645,"src":"Resize-Wizard-1-Moody_thumb.jpg","galleries_id":62528,"server_id":18,"link":"photo_820645.html","width":130,"caption":"","height":92});
															thumbnails[1274700] = clik.newPhoto({"id":1274700,"src":"Resize Wizard-14_thumb.jpg","galleries_id":70799,"server_id":18,"link":"photo_1274700.html","width":130,"caption":"","height":87});
															thumbnails[1284481] = clik.newPhoto({"id":1284481,"src":"KT Head Sharp_thumb.jpg","galleries_id":63634,"server_id":18,"link":"photo_1284481.html","width":130,"caption":"Katie","height":196});
															thumbnails[1290559] = clik.newPhoto({"id":1290559,"src":"Exb-S&J-Hill-low_thumb.jpg","galleries_id":76077,"server_id":18,"link":"photo_1290559.html","width":130,"caption":"","height":130});
															thumbnails[3472827] = clik.newPhoto({"id":3472827,"src":"Picture12_thumb.jpg","galleries_id":63639,"server_id":18,"link":"photo_3472827.html","width":130,"caption":"Single Man!","height":131});
															thumbnails[8573543] = clik.newPhoto({"id":8573543,"src":"flyer_ideas-1_thumb.jpg","galleries_id":458997,"server_id":18,"link":"photo_8573543.html","width":130,"caption":"","height":92});
															thumbnails[1274696] = clik.newPhoto({"id":1274696,"src":"Resize Wizard-10_thumb.jpg","galleries_id":70799,"server_id":18,"link":"photo_1274696.html","width":130,"caption":"","height":87});
															thumbnails[1274705] = clik.newPhoto({"id":1274705,"src":"Resize Wizard-18_thumb.jpg","galleries_id":70799,"server_id":18,"link":"photo_1274705.html","width":130,"caption":"","height":87});
															thumbnails[820559] = clik.newPhoto({"id":820559,"src":"Resize-Wizard-1-Bee_thumb.jpg","galleries_id":62528,"server_id":18,"link":"photo_820559.html","width":130,"caption":"","height":95});
															thumbnails[1015087] = clik.newPhoto({"id":1015087,"src":"Lora_thumb.jpg","galleries_id":63634,"server_id":18,"link":"photo_1015087.html","width":130,"caption":"Lora","height":191});
															thumbnails[8700781] = clik.newPhoto({"id":8700781,"src":"Steffi-4010_thumb.gif","galleries_id":458997,"server_id":18,"link":"photo_8700781.html","width":130,"caption":"Stephanie","height":98});
															thumbnails[1274695] = clik.newPhoto({"id":1274695,"src":"Resize Wizard-9_thumb.jpg","galleries_id":70799,"server_id":18,"link":"photo_1274695.html","width":130,"caption":"","height":87});
															thumbnails[1274694] = clik.newPhoto({"id":1274694,"src":"Resize Wizard-8_thumb.jpg","galleries_id":70799,"server_id":18,"link":"photo_1274694.html","width":130,"caption":"","height":87});
															thumbnails[820572] = clik.newPhoto({"id":820572,"src":"Resize-Wizard-1-lily_thumb.jpg","galleries_id":62528,"server_id":18,"link":"photo_820572.html","width":130,"caption":"","height":86});
															thumbnails[1290667] = clik.newPhoto({"id":1290667,"src":"Exb-KT-Bath-low1_thumb.jpg","galleries_id":76077,"server_id":18,"link":"photo_1290667.html","width":130,"caption":"","height":130});
															thumbnails[3472791] = clik.newPhoto({"id":3472791,"src":"Picture21_thumb.jpg","galleries_id":63639,"server_id":18,"link":"photo_3472791.html","width":130,"caption":"Ebony Mirror","height":131});
															thumbnails[8700784] = clik.newPhoto({"id":8700784,"src":"Odin_5101-c_thumb.gif","galleries_id":458997,"server_id":18,"link":"photo_8700784.html","width":130,"caption":"Odin","height":104});
															thumbnails[1274704] = clik.newPhoto({"id":1274704,"src":"Resize Wizard-17_thumb.jpg","galleries_id":70799,"server_id":18,"link":"photo_1274704.html","width":130,"caption":"","height":93});
															thumbnails[1016933] = clik.newPhoto({"id":1016933,"src":"Cowboy_thumb.jpg","galleries_id":63634,"server_id":18,"link":"photo_1016933.html","width":130,"caption":"Young Cowboy","height":196});
															thumbnails[1442948] = clik.newPhoto({"id":1442948,"src":"Pheasant1_thumb.jpg","galleries_id":62528,"server_id":18,"link":"photo_1442948.html","width":130,"caption":"","height":123});
															thumbnails[1274684] = clik.newPhoto({"id":1274684,"src":"Resize Wizard-1_thumb.jpg","galleries_id":70799,"server_id":18,"link":"photo_1274684.html","width":130,"caption":"","height":195});
															thumbnails[820580] = clik.newPhoto({"id":820580,"src":"Resize-Wizard-1-open-tulip_thumb.jpg","galleries_id":62528,"server_id":18,"link":"photo_820580.html","width":130,"caption":"","height":186});
															thumbnails[1290597] = clik.newPhoto({"id":1290597,"src":"Exb-Jim-Cooker-low_thumb.jpg","galleries_id":76077,"server_id":18,"link":"photo_1290597.html","width":130,"caption":"","height":130});
															thumbnails[3472793] = clik.newPhoto({"id":3472793,"src":"Picture31_thumb.jpg","galleries_id":63639,"server_id":18,"link":"photo_3472793.html","width":130,"caption":"Favourite Novels","height":131});
															thumbnails[1016931] = clik.newPhoto({"id":1016931,"src":"Darcy_thumb.jpg","galleries_id":63634,"server_id":18,"link":"photo_1016931.html","width":130,"caption":"D'arcy","height":87});
															thumbnails[1442942] = clik.newPhoto({"id":1442942,"src":"Heron_thumb.jpg","galleries_id":62528,"server_id":18,"link":"photo_1442942.html","width":130,"caption":"","height":196});
															thumbnails[1274687] = clik.newPhoto({"id":1274687,"src":"Resize Wizard-2_thumb.jpg","galleries_id":70799,"server_id":18,"link":"photo_1274687.html","width":130,"caption":"","height":130});
															thumbnails[1284700] = clik.newPhoto({"id":1284700,"src":"Beau Sb BW_thumb.jpg","galleries_id":70799,"server_id":18,"link":"photo_1284700.html","width":130,"caption":"","height":86});
															thumbnails[1290612] = clik.newPhoto({"id":1290612,"src":"Exb-M&L-TV-low_thumb.jpg","galleries_id":76077,"server_id":18,"link":"photo_1290612.html","width":130,"caption":"","height":130});
															thumbnails[3472794] = clik.newPhoto({"id":3472794,"src":"Picture41_thumb.jpg","galleries_id":63639,"server_id":18,"link":"photo_3472794.html","width":130,"caption":"Hughes Keys","height":131});
															thumbnails[820598] = clik.newPhoto({"id":820598,"src":"Resize-Wizard-1-Tulip_thumb.jpg","galleries_id":62528,"server_id":18,"link":"photo_820598.html","width":130,"caption":"","height":186});
															thumbnails[1015090] = clik.newPhoto({"id":1015090,"src":"Nelson_thumb.jpg","galleries_id":63634,"server_id":18,"link":"photo_1015090.html","width":130,"caption":"Nelson!","height":86});
															thumbnails[1015098] = clik.newPhoto({"id":1015098,"src":"Jump!_thumb.jpg","galleries_id":63634,"server_id":18,"link":"photo_1015098.html","width":130,"caption":"Jump!<br>\r\n","height":87});
															thumbnails[1290635] = clik.newPhoto({"id":1290635,"src":"Exb-John-Dog-low_thumb.jpg","galleries_id":76077,"server_id":18,"link":"photo_1290635.html","width":130,"caption":"","height":130});
															thumbnails[3472786] = clik.newPhoto({"id":3472786,"src":"Picture6_thumb.jpg","galleries_id":63639,"server_id":18,"link":"photo_3472786.html","width":130,"caption":"Assorted Photos","height":130});
															thumbnails[1015088] = clik.newPhoto({"id":1015088,"src":"Matt Surf_thumb.jpg","galleries_id":63634,"server_id":18,"link":"photo_1015088.html","width":130,"caption":"Matt","height":86});
															thumbnails[3472795] = clik.newPhoto({"id":3472795,"src":"Picture7_thumb.jpg","galleries_id":63639,"server_id":18,"link":"photo_3472795.html","width":130,"caption":"Tiger Eye Ring","height":131});
															thumbnails[3472796] = clik.newPhoto({"id":3472796,"src":"Picture8_thumb.jpg","galleries_id":63639,"server_id":18,"link":"photo_3472796.html","width":130,"caption":"Letter Clip","height":131});
															thumbnails[1299012] = clik.newPhoto({"id":1299012,"src":"Frame 50 x 50_thumb.jpg","galleries_id":76077,"server_id":18,"link":"photo_1299012.html","width":130,"caption":"Framed 50cms x 50cms Beechwood ","height":130});
															thumbnails[3472797] = clik.newPhoto({"id":3472797,"src":"Picture9_thumb.jpg","galleries_id":63639,"server_id":18,"link":"photo_3472797.html","width":130,"caption":"Project presentation","height":130});

/***************************************************************************
* Create the array of Gallery objects                                      *
***************************************************************************/
var galleries = new Object();
				  						galleries[137233] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Incandescence","link":"gallery_137233.html","maxRecords":0.0,"photoIDs":[2208930.0,2208933.0,2208934.0,2208936.0,2208938.0],"skipIndex":0,"section_code":"gallery","featured_images":2208938.0,"id":137233,"singleSection":false});				  						galleries[458997] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"So The Wind Won't Blow It All Away","link":"gallery_458997.html","maxRecords":0.0,"photoIDs":[8573543.0,8700781.0,8700784.0],"skipIndex":0,"section_code":"gallery","featured_images":"8700784,8700781,8573543","id":458997,"singleSection":false});				  						galleries[76077] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Our Green & Pleasant Land","link":"gallery_76077.html","maxRecords":0.0,"photoIDs":[1290670.0,1290559.0,1290667.0,1290597.0,1290612.0,1290635.0,1299012.0],"skipIndex":0,"section_code":"gallery","featured_images":1290667.0,"id":76077,"singleSection":false});				  						galleries[76078] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Documentary","link":"gallery_76078.html","maxRecords":0.0,"photoIDs":[1017433.0,1017450.0,1017461.0],"skipIndex":0,"section_code":"gallery","featured_images":"1017461,1017450,1017433","id":76078,"singleSection":false});				  						galleries[63639] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Memories","link":"gallery_63639.html","maxRecords":0.0,"photoIDs":[3472827.0,3472791.0,3472793.0,3472794.0,3472786.0,3472795.0,3472796.0,3472797.0],"skipIndex":0,"section_code":"gallery","featured_images":"3472827,3472797,3472796,3472795,3472794,3472793,3472791,3472786","id":63639,"singleSection":false});				  						galleries[159458] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Poppy Line","link":"gallery_159458.html","maxRecords":0.0,"photoIDs":[2484467.0,2484468.0,2484469.0,2484470.0,2484471.0,2484472.0,2484473.0,2484474.0,2484475.0,2484476.0,2484477.0],"skipIndex":0,"section_code":"gallery","featured_images":2484471.0,"id":159458,"singleSection":false});				  						galleries[63636] = clik.newGallery({"parentGallery":230957,"usePopups":false,"title":"Abstract","link":"gallery_63636.html","maxRecords":0.0,"photoIDs":[820785.0,3832323.0],"skipIndex":0,"section_code":"gallery","featured_images":"3832323,820785","id":63636,"singleSection":false});				  						galleries[230957] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Casual","link":"gallery_230957.html","maxRecords":0.0,"photoIDs":[],"skipIndex":0,"section_code":"gallery","featured_images":"3605197,1285696,1274701,1015087,1014411,820809,820572","id":230957,"singleSection":false});				  						galleries[63634] = clik.newGallery({"parentGallery":230957,"usePopups":false,"title":"People","link":"gallery_63634.html","maxRecords":0.0,"photoIDs":[2053941.0,1284481.0,1015087.0,1016933.0,1016931.0,1015090.0,1015098.0,1015088.0],"skipIndex":0,"section_code":"gallery","featured_images":1015087.0,"id":63634,"singleSection":false});				  						galleries[70799] = clik.newGallery({"parentGallery":230957,"usePopups":false,"title":"Weddings","link":"gallery_70799.html","maxRecords":0.0,"photoIDs":[1274698.0,1274701.0,1274709.0,1274700.0,1274696.0,1274705.0,1274695.0,1274694.0,1274704.0,1274684.0,1274687.0,1284700.0],"skipIndex":0,"section_code":"gallery","featured_images":1274701.0,"id":70799,"singleSection":false});				  						galleries[62528] = clik.newGallery({"parentGallery":230957,"usePopups":false,"title":"Flora & Fauna","link":"gallery_62528.html","maxRecords":0.0,"photoIDs":[820645.0,820559.0,820572.0,1442948.0,820580.0,1442942.0,820598.0],"skipIndex":0,"section_code":"gallery","featured_images":820572.0,"id":62528,"singleSection":false});				  						galleries[75920] = clik.newGallery({"parentGallery":230957,"usePopups":false,"title":"Landscape","link":"gallery_75920.html","maxRecords":0.0,"photoIDs":[1014409.0,1014410.0,1014411.0,1015101.0,1016935.0,1017396.0,1017399.0,1285696.0,3485318.0,3605197.0,3605198.0,3605201.0],"skipIndex":0,"section_code":"gallery","featured_images":"3605197,1285696,1014411","id":75920,"singleSection":false});				  						galleries[99820] = clik.newGallery({"parentGallery":230957,"usePopups":false,"title":"Film Stills","link":"gallery_99820.html","maxRecords":0.0,"photoIDs":[1443070.0,1443072.0],"skipIndex":0,"section_code":"gallery","featured_images":"1443072,1443070","id":99820,"singleSection":false});				  						galleries[63655] = clik.newGallery({"parentGallery":230957,"usePopups":false,"title":"Bands","link":"gallery_63655.html","maxRecords":0.0,"photoIDs":[820809.0,820848.0,820854.0,820860.0,820866.0,820869.0],"skipIndex":0,"section_code":"gallery","featured_images":820809.0,"id":63655,"singleSection":false});				  						galleries[158287] = clik.newGallery({"parentGallery":230957,"usePopups":false,"title":"Theatre","link":"gallery_158287.html","maxRecords":0.0,"photoIDs":[2240503.0],"skipIndex":0,"section_code":"gallery","featured_images":2240503.0,"id":158287,"singleSection":false});/***************************************************************************
* Create the array of image sets                                           *
***************************************************************************/
var imageSets = {};
imageSets[246540] = '8860815';
imageSets[1] = '2208938';
imageSets[2] = '3605197,2484471,2208938,1443073,1285696,1014411,820809,1274701,1015087,1290667,820572';
imageSets[245442] = '8573543';
imageSets[3] = '8860815,8700784,8700781,8573543,3832323,3605201,3605198,3605197,3485318,3472827,3472797,3472796,3472795,3472794,3472793,3472791,3472786,2484477,2484476,2484475,2484474,2484473,2484472,2484471,2484470,2484469,2484468,2484467,2240503,2208938,2208936,2208934,2208933,2208930,2053941,1443073,1443072,1443070,1442948,1442942,1299012,1290670,1290667,1290635,1290612,1290597,1290559,1285696,1284700,1284481';
 /***************************************************************************
* Get a server path given an ID                                            *
***************************************************************************/
function getServerPath(server_id) {
	var val = -1;
		switch (server_id) {
		case 51:
		val = 'http://www12.clikpic.com/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 0:
		val = 'http://www.clikpic.com/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 1:
		val = 'http://www1.clikpic.com/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 2:
		val = 'http://admin.clikpic.com/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 24:
		val = 'http://tpc15/clikpic/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 4:
		val = 'http://clikchurch.clikpic.com/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 5:
		val = 'http://www2.clikpic.com/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 22:
		val = 'http://tpc5/clikpic/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 23:
		val = 'http://tpc10/clikpic/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 25:
		val = 'http://tpc16/clikpic/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 26:
		val = 'http://tpc20/clikpic/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 40:
		val = 'http://www11.clikpic.com/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 42:
		val = 'db2.clikpic.com/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 15:
		val = 'http://www3.clikpic.com/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 18:
		val = 'http://www4.clikpic.com/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 19:
		val = 'http://www5.clikpic.com/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 31:
		val = 'http://www7.clikpic.com/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 32:
		val = 'http://www8.clikpic.com/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 34:
		val = 'http://www9.clikpic.com/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 35:
		val = 'http://admin3.clikpic.com/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 37:
		val = 'http://admin4.clikpic.com/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 38:
		val = 'http://admin5.clikpic.com/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 39:
		val = 'http://www10.clikpic.com/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 53:
		val = 'http://images.clikpic.com/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 52:
		val = 'http://tpc22/clikpic/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 21:
		val = 'http://www6.clikpic.com/maeveberry/images';
		break;
	}
		switch (server_id) {
		case 50:
		val = '[cliktext value=article.servers_id type=servers_id]/maeveberry/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 = 'Maeve Berry 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>';
	}
				
				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.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;
	}
}

			

