window.thumbnails = {};
															thumbnails[2845676] = clik.newPhoto({"id":2845676,"src":"SH7_2429a_thumb.jpg","galleries_id":29564,"server_id":18,"link":"photo_2845676.html","width":130,"caption":"Snail","height":130});
															thumbnails[2845666] = clik.newPhoto({"id":2845666,"src":"AJH_5289shaun-copy_thumb.jpg","galleries_id":29564,"server_id":18,"link":"photo_2845666.html","width":130,"caption":"","height":195});
															thumbnails[2845671] = clik.newPhoto({"id":2845671,"src":"AJH_5288-copy_thumb.jpg","galleries_id":29564,"server_id":18,"link":"photo_2845671.html","width":130,"caption":"","height":195});
															thumbnails[1740136] = clik.newPhoto({"id":1740136,"src":"circles_thumb.jpg","galleries_id":116887,"server_id":18,"link":"photo_1740136.html","width":130,"caption":"Tree in a Circle","height":130});
															thumbnails[1740141] = clik.newPhoto({"id":1740141,"src":"circles1_thumb.jpg","galleries_id":116887,"server_id":18,"link":"photo_1740141.html","width":130,"caption":"Palm House in a Circle","height":130});
															thumbnails[3039621] = clik.newPhoto({"id":3039621,"src":"SH7_3893_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_3039621.html","width":130,"caption":"","height":87});
															thumbnails[1740144] = clik.newPhoto({"id":1740144,"src":"circles2_thumb.jpg","galleries_id":116887,"server_id":18,"link":"photo_1740144.html","width":130,"caption":"Shrubs in a Circle","height":130});
															thumbnails[3039605] = clik.newPhoto({"id":3039605,"src":"DSC_0072_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_3039605.html","width":130,"caption":"","height":87});
															thumbnails[2833243] = clik.newPhoto({"id":2833243,"src":"SH7_0594_thumb.jpg","galleries_id":29790,"server_id":18,"link":"photo_2833243.html","width":130,"caption":"Gravestones","height":87});
															thumbnails[1740118] = clik.newPhoto({"id":1740118,"src":"DSC_0048_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_1740118.html","width":130,"caption":"","height":87});
															thumbnails[521656] = clik.newPhoto({"id":521656,"src":"StPauls_Original_verygood_thumb.jpg","galleries_id":29536,"server_id":18,"link":"photo_521656.html","width":130,"caption":"St Pauls and the Millenium Bridge","height":87});
															thumbnails[1740193] = clik.newPhoto({"id":1740193,"src":"the-flygif1_thumb.jpg","galleries_id":116887,"server_id":18,"link":"photo_1740193.html","width":130,"caption":"The Fly","height":194});
															thumbnails[2833234] = clik.newPhoto({"id":2833234,"src":"DSC_4868a_thumb.jpg","galleries_id":29790,"server_id":18,"link":"photo_2833234.html","width":130,"caption":"Sunrise in Africa","height":87});
															thumbnails[2833241] = clik.newPhoto({"id":2833241,"src":"DSC_4890_thumb.jpg","galleries_id":29790,"server_id":18,"link":"photo_2833241.html","width":130,"caption":"Sunrise in Africa","height":87});
															thumbnails[377368] = clik.newPhoto({"id":377368,"src":"created_crane_thumb.jpg","galleries_id":29567,"server_id":18,"link":"photo_377368.html","width":130,"caption":"Crested Crane","height":102});
															thumbnails[361015] = clik.newPhoto({"id":361015,"src":"his_ani_004_thumb.jpg","galleries_id":29564,"server_id":18,"link":"photo_361015.html","width":130,"caption":"Lying in wait.","height":87});
															thumbnails[1637228] = clik.newPhoto({"id":1637228,"src":"Anthurium-Blurred_thumb.jpg","galleries_id":133055,"server_id":18,"link":"photo_1637228.html","width":130,"caption":"Taken at home a beautiful Anthurium","height":102});
															thumbnails[1737972] = clik.newPhoto({"id":1737972,"src":"StPauls_Custom_thumb.jpg","galleries_id":29536,"server_id":18,"link":"photo_1737972.html","width":130,"caption":"St Paul's and the Millenium Bridge","height":90});
															thumbnails[1743753] = clik.newPhoto({"id":1743753,"src":"balito_thumb.jpg","galleries_id":29790,"server_id":18,"link":"photo_1743753.html","width":130,"caption":"Balito seascape","height":88});
															thumbnails[2833230] = clik.newPhoto({"id":2833230,"src":"_SH7_0582_thumb.jpg","galleries_id":29790,"server_id":18,"link":"photo_2833230.html","width":130,"caption":"Wobbly gravestones","height":52});
															thumbnails[8934517] = clik.newPhoto({"id":8934517,"src":"High_Pikes_from_Skelwith_SH7_8041_6D8CA61B-1EC9-DFB6-0987589D44F75E24_thumb.jpg","galleries_id":470149,"server_id":18,"link":"photo_8934517.html","width":130,"caption":"High Pikes from Skelwith SH7 8041","height":51});
															thumbnails[8934725] = clik.newPhoto({"id":8934725,"src":"city_girl_1_717B2955-1EC9-D45B-1C9DC9C5D9DC25DC_thumb.jpg","galleries_id":470166,"server_id":18,"link":"photo_8934725.html","width":130,"caption":"city girl 1","height":195});
															thumbnails[8934735] = clik.newPhoto({"id":8934735,"src":"Vogue_Bettie_719463EB-1EC9-D45B-1CF4F4D04792ADBA_thumb.jpg","galleries_id":470167,"server_id":18,"link":"photo_8934735.html","width":130,"caption":"Vogue Bettie","height":87});
															thumbnails[1974514] = clik.newPhoto({"id":1974514,"src":"SH7_3641a_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_1974514.html","width":130,"caption":"HonisterPass","height":87});
															thumbnails[3039310] = clik.newPhoto({"id":3039310,"src":"DSC_0010_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_3039310.html","width":130,"caption":"","height":87});
															thumbnails[3039334] = clik.newPhoto({"id":3039334,"src":"SH7_3850_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_3039334.html","width":130,"caption":"","height":87});
															thumbnails[3039619] = clik.newPhoto({"id":3039619,"src":"SH7_3530_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_3039619.html","width":130,"caption":"","height":195});
															thumbnails[3039620] = clik.newPhoto({"id":3039620,"src":"SH7_3627_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_3039620.html","width":130,"caption":"","height":195});
															thumbnails[3039610] = clik.newPhoto({"id":3039610,"src":"SH7_3522_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_3039610.html","width":130,"caption":"","height":195});
															thumbnails[3039376] = clik.newPhoto({"id":3039376,"src":"SH7_3940_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_3039376.html","width":130,"caption":"","height":195});
															thumbnails[3039311] = clik.newPhoto({"id":3039311,"src":"SH7_3540_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_3039311.html","width":130,"caption":"","height":195});
															thumbnails[3039321] = clik.newPhoto({"id":3039321,"src":"SH7_3635_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_3039321.html","width":130,"caption":"","height":195});
															thumbnails[3039317] = clik.newPhoto({"id":3039317,"src":"SH7_3599_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_3039317.html","width":130,"caption":"","height":195});
															thumbnails[3039747] = clik.newPhoto({"id":3039747,"src":"DSC_0036_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_3039747.html","width":130,"caption":"","height":195});
															thumbnails[3039316] = clik.newPhoto({"id":3039316,"src":"SH7_3588_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_3039316.html","width":130,"caption":"","height":87});
															thumbnails[363192] = clik.newPhoto({"id":363192,"src":"orangatan_thumb.jpg","galleries_id":29564,"server_id":18,"link":"photo_363192.html","width":130,"caption":"A very expressive Orangataun","height":87});
															thumbnails[1637235] = clik.newPhoto({"id":1637235,"src":"Anthurium-red_thumb.jpg","galleries_id":133055,"server_id":18,"link":"photo_1637235.html","width":130,"caption":"A red Anthurium","height":194});
															thumbnails[1737975] = clik.newPhoto({"id":1737975,"src":"StPauls_Square_Flourescent_thumb.jpg","galleries_id":29536,"server_id":18,"link":"photo_1737975.html","width":130,"caption":"St Pauls and the Millenium Bridge","height":130});
															thumbnails[1743754] = clik.newPhoto({"id":1743754,"src":"balito2_thumb.jpg","galleries_id":29790,"server_id":18,"link":"photo_1743754.html","width":130,"caption":"Balito seascape","height":88});
															thumbnails[8934510] = clik.newPhoto({"id":8934510,"src":"SH7_7938-Edit_thumb.jpg","galleries_id":470149,"server_id":18,"link":"photo_8934510.html","width":130,"caption":"","height":65});
															thumbnails[8934726] = clik.newPhoto({"id":8934726,"src":"city_girl_2-Edit_717B8B41-1EC9-D45B-1CA2A11213C7B393_thumb.jpg","galleries_id":470166,"server_id":18,"link":"photo_8934726.html","width":130,"caption":"city girl 2","height":165});
															thumbnails[8934736] = clik.newPhoto({"id":8934736,"src":"Vogue_Cheryl_7194C39C-1EC9-D45B-1C585ECCAAE16DE4_thumb.jpg","galleries_id":470167,"server_id":18,"link":"photo_8934736.html","width":130,"caption":"Vogue Cheryl","height":87});
															thumbnails[3039319] = clik.newPhoto({"id":3039319,"src":"SH7_3616_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_3039319.html","width":130,"caption":"","height":87});
															thumbnails[3039384] = clik.newPhoto({"id":3039384,"src":"SH7_3912_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_3039384.html","width":130,"caption":"","height":87});
															thumbnails[3039633] = clik.newPhoto({"id":3039633,"src":"SH7_3879_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_3039633.html","width":130,"caption":"","height":87});
															thumbnails[3039313] = clik.newPhoto({"id":3039313,"src":"SH7_3543_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_3039313.html","width":130,"caption":"","height":87});
															thumbnails[3039623] = clik.newPhoto({"id":3039623,"src":"SH7_3854_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_3039623.html","width":130,"caption":"","height":87});
															thumbnails[3039379] = clik.newPhoto({"id":3039379,"src":"SH7_3952_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_3039379.html","width":130,"caption":"","height":87});
															thumbnails[3039635] = clik.newPhoto({"id":3039635,"src":"SH7_3890_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_3039635.html","width":130,"caption":"","height":87});
															thumbnails[3039615] = clik.newPhoto({"id":3039615,"src":"AJH_5696-as-Smart-Object-1-4_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_3039615.html","width":130,"caption":"","height":87});
															thumbnails[363194] = clik.newPhoto({"id":363194,"src":"giraffe_001_thumb.jpg","galleries_id":29564,"server_id":18,"link":"photo_363194.html","width":130,"caption":"Giraffe","height":87});
															thumbnails[1637200] = clik.newPhoto({"id":1637200,"src":"British-Museum-Columns_thumb.jpg","galleries_id":29536,"server_id":18,"link":"photo_1637200.html","width":130,"caption":"The columns outside the British Museum","height":195});
															thumbnails[1740127] = clik.newPhoto({"id":1740127,"src":"the-button-2_thumb.jpg","galleries_id":116887,"server_id":18,"link":"photo_1740127.html","width":130,"caption":"One button and I'm free","height":87});
															thumbnails[1743836] = clik.newPhoto({"id":1743836,"src":"Birds-in-Flight-BW_thumb.jpg","galleries_id":29790,"server_id":18,"link":"photo_1743836.html","width":130,"caption":"Three birds in Flight","height":88});
															thumbnails[8934518] = clik.newPhoto({"id":8934518,"src":"SH7_7895-Edit_6D8D15F6-1EC9-DFB6-09CACE904A94D7D0_thumb.jpg","galleries_id":470149,"server_id":18,"link":"photo_8934518.html","width":130,"caption":"SH7 7895-Edit","height":130});
															thumbnails[8934727] = clik.newPhoto({"id":8934727,"src":"city_girl_3_717BEF40-1EC9-D45B-1C4CF488062F28BA_thumb.jpg","galleries_id":470166,"server_id":18,"link":"photo_8934727.html","width":130,"caption":"city girl 3","height":195});
															thumbnails[362369] = clik.newPhoto({"id":362369,"src":"hyena_002_thumb.jpg","galleries_id":29564,"server_id":18,"link":"photo_362369.html","width":130,"caption":"Scary Hyena","height":102});
															thumbnails[1637204] = clik.newPhoto({"id":1637204,"src":"Reading-Room_thumb.jpg","galleries_id":29536,"server_id":18,"link":"photo_1637204.html","width":130,"caption":"The Reading Room, British Museum","height":130});
															thumbnails[1743757] = clik.newPhoto({"id":1743757,"src":"lucerne_thumb.jpg","galleries_id":29790,"server_id":18,"link":"photo_1743757.html","width":130,"caption":"Lake Lucerne","height":87});
															thumbnails[8934520] = clik.newPhoto({"id":8934520,"src":"SH7_7959-Edit_6D8DDD84-1EC9-DFB6-0911AC151A717A4D_thumb.jpg","galleries_id":470149,"server_id":18,"link":"photo_8934520.html","width":130,"caption":"SH7 7959-Edit","height":54});
															thumbnails[8934728] = clik.newPhoto({"id":8934728,"src":"SH7_7684-Edit_717C6216-1EC9-D45B-1C8D857FDA2289B5_thumb.jpg","galleries_id":470166,"server_id":18,"link":"photo_8934728.html","width":130,"caption":"SH7 7684-Edit","height":130});
															thumbnails[3039323] = clik.newPhoto({"id":3039323,"src":"SH7_3724_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_3039323.html","width":130,"caption":"","height":87});
															thumbnails[363537] = clik.newPhoto({"id":363537,"src":"london_eye_001_thumb.jpg","galleries_id":29536,"server_id":18,"link":"photo_363537.html","width":130,"caption":"London Eye","height":86});
															thumbnails[1974124] = clik.newPhoto({"id":1974124,"src":"white_peaks_kew-2007_thumb.jpg","galleries_id":29790,"server_id":18,"link":"photo_1974124.html","width":130,"caption":"White Peaks Kew Gardens London","height":86});
															thumbnails[2845600] = clik.newPhoto({"id":2845600,"src":"AJH_4119_loxley_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_2845600.html","width":130,"caption":"","height":87});
															thumbnails[2845607] = clik.newPhoto({"id":2845607,"src":"AJH_4485_loxley_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_2845607.html","width":130,"caption":"","height":87});
															thumbnails[8934521] = clik.newPhoto({"id":8934521,"src":"SH7_8206_as_Smart_Object-1_6D8E5B8A-1EC9-DFB6-092C3E21EFCE7793_thumb.jpg","galleries_id":470149,"server_id":18,"link":"photo_8934521.html","width":130,"caption":"SH7 8206","height":84});
															thumbnails[8934729] = clik.newPhoto({"id":8934729,"src":"SH7_7686-Edit-Edit_717CC6AB-1EC9-D45B-1C7AB3AB40D81028_thumb.jpg","galleries_id":470166,"server_id":18,"link":"photo_8934729.html","width":130,"caption":"SH7 7686-Edit-Edit","height":195});
															thumbnails[2845652] = clik.newPhoto({"id":2845652,"src":"sheep3_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_2845652.html","width":130,"caption":"","height":87});
															thumbnails[2845604] = clik.newPhoto({"id":2845604,"src":"AJH_4278_loxley_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_2845604.html","width":130,"caption":"","height":195});
															thumbnails[2845601] = clik.newPhoto({"id":2845601,"src":"AJH_4272_loxley_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_2845601.html","width":130,"caption":"","height":195});
															thumbnails[2845606] = clik.newPhoto({"id":2845606,"src":"AJH_4414_loxley_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_2845606.html","width":130,"caption":"","height":195});
															thumbnails[2845651] = clik.newPhoto({"id":2845651,"src":"sheep2_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_2845651.html","width":130,"caption":"","height":87});
															thumbnails[3039631] = clik.newPhoto({"id":3039631,"src":"SH7_3983_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_3039631.html","width":130,"caption":"","height":52});
															thumbnails[360946] = clik.newPhoto({"id":360946,"src":"waterbuck_0011_thumb.jpg","galleries_id":29564,"server_id":18,"link":"photo_360946.html","width":130,"caption":"Waterbuck","height":88});
															thumbnails[1637218] = clik.newPhoto({"id":1637218,"src":"The-Forest_thumb.jpg","galleries_id":29790,"server_id":18,"link":"photo_1637218.html","width":130,"caption":"A wonderful forest scene","height":87});
															thumbnails[1737962] = clik.newPhoto({"id":1737962,"src":"LondonEye_Selenium_thumb.jpg","galleries_id":29536,"server_id":18,"link":"photo_1737962.html","width":130,"caption":"The London Eye with a Selenium finish","height":86});
															thumbnails[2845609] = clik.newPhoto({"id":2845609,"src":"AJH_4491_loxley_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_2845609.html","width":130,"caption":"","height":87});
															thumbnails[8934522] = clik.newPhoto({"id":8934522,"src":"The_Langdale_Pikes_from_the_valley_floor._SH7_7982-Edit-2_6D8EC546-1EC9-DFB6-0969C0B33699BAC7_thumb.jpg","galleries_id":470149,"server_id":18,"link":"photo_8934522.html","width":130,"caption":"The Langdale Pikes from the valley floor. SH7 7982-Edit-2","height":130});
															thumbnails[8934731] = clik.newPhoto({"id":8934731,"src":"SH7_7705-Edit-Edit-Edit-2-Edit_717D2FAE-1EC9-D45B-1CCF94FE7B269080_thumb.jpg","galleries_id":470166,"server_id":18,"link":"photo_8934731.html","width":130,"caption":"SH7 7705","height":165});
															thumbnails[1740123] = clik.newPhoto({"id":1740123,"src":"SH7_3631aa_web_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_1740123.html","width":130,"caption":"","height":66});
															thumbnails[2845648] = clik.newPhoto({"id":2845648,"src":"AJH_4928a_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_2845648.html","width":130,"caption":"","height":52});
															thumbnails[1737956] = clik.newPhoto({"id":1737956,"src":"london_eye_003-1_thumb.jpg","galleries_id":29536,"server_id":18,"link":"photo_1737956.html","width":130,"caption":"The London Eye","height":196});
															thumbnails[2845641] = clik.newPhoto({"id":2845641,"src":"AJH_4559_loxley_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_2845641.html","width":130,"caption":"","height":87});
															thumbnails[360939] = clik.newPhoto({"id":360939,"src":"zebra_001_thumb.jpg","galleries_id":29564,"server_id":18,"link":"photo_360939.html","width":130,"caption":"Stunning Zebra","height":87});
															thumbnails[1974539] = clik.newPhoto({"id":1974539,"src":"Switched_on_London_8_thumb.jpg","galleries_id":29536,"server_id":18,"link":"photo_1974539.html","width":130,"caption":"Switched on London 2008. A very cold walk along the embankment","height":130});
															thumbnails[8934732] = clik.newPhoto({"id":8934732,"src":"SH7_7705-Edit-Edit-Edit-Edit_717D92B0-1EC9-D45B-1CFF1D6412197CCD_thumb.jpg","galleries_id":470166,"server_id":18,"link":"photo_8934732.html","width":130,"caption":"SH7 7705","height":195});
															thumbnails[363216] = clik.newPhoto({"id":363216,"src":"lioness_001_thumb.jpg","galleries_id":29564,"server_id":18,"link":"photo_363216.html","width":130,"caption":"Lioness relaxing after a feed","height":87});
															thumbnails[362373] = clik.newPhoto({"id":362373,"src":"kudu_001_thumb.jpg","galleries_id":29564,"server_id":18,"link":"photo_362373.html","width":130,"caption":"Kudu in its natural enviroment","height":87});
															thumbnails[1974553] = clik.newPhoto({"id":1974553,"src":"Switched_on_London_7_thumb.jpg","galleries_id":29536,"server_id":18,"link":"photo_1974553.html","width":130,"caption":"Switched on London 2008","height":74});
															thumbnails[8934524] = clik.newPhoto({"id":8934524,"src":"The_Langdale_Pikes_from_the_valley_floor._SH7_7982_6D8F90B2-1EC9-DFB6-09D2781D9CCC8299_thumb.jpg","galleries_id":470149,"server_id":18,"link":"photo_8934524.html","width":130,"caption":"The Langdale Pikes from the valley floor. SH7 7982","height":130});
															thumbnails[363190] = clik.newPhoto({"id":363190,"src":"zebra_002_thumb.jpg","galleries_id":29564,"server_id":18,"link":"photo_363190.html","width":130,"caption":"There is always one stuborn teenager with attitude","height":97});
															thumbnails[1974560] = clik.newPhoto({"id":1974560,"src":"Switched_on_London_4_thumb.jpg","galleries_id":29536,"server_id":18,"link":"photo_1974560.html","width":130,"caption":"Switched on London 2008","height":78});
															thumbnails[8934525] = clik.newPhoto({"id":8934525,"src":"The_Langdale_Pikes_from_the_valley_floor._SH7_7988-2_6D8FF869-1EC9-DFB6-09A9FA6D663C80EA_thumb.jpg","galleries_id":470149,"server_id":18,"link":"photo_8934525.html","width":130,"caption":"The Langdale Pikes from the valley floor. SH7 7988-2","height":130});
															thumbnails[2485258] = clik.newPhoto({"id":2485258,"src":"_SHI1982_thumb.jpg","galleries_id":131139,"server_id":18,"link":"photo_2485258.html","width":130,"caption":"Monique","height":194});
															thumbnails[2485251] = clik.newPhoto({"id":2485251,"src":"_SHI1971ani_thumb.jpg","galleries_id":131139,"server_id":18,"link":"photo_2485251.html","width":130,"caption":"Monique animated","height":194});
															thumbnails[2485233] = clik.newPhoto({"id":2485233,"src":"_SHI1952_thumb.jpg","galleries_id":131139,"server_id":18,"link":"photo_2485233.html","width":130,"caption":"Monique","height":194});
															thumbnails[2485222] = clik.newPhoto({"id":2485222,"src":"_SHI1929_thumb.jpg","galleries_id":131139,"server_id":18,"link":"photo_2485222.html","width":130,"caption":"Monique","height":194});
															thumbnails[2485203] = clik.newPhoto({"id":2485203,"src":"_SHI1920_thumb.jpg","galleries_id":131139,"server_id":18,"link":"photo_2485203.html","width":130,"caption":"Monique","height":195});
															thumbnails[2485228] = clik.newPhoto({"id":2485228,"src":"_SHI1934_thumb.jpg","galleries_id":131139,"server_id":18,"link":"photo_2485228.html","width":130,"caption":"Monique","height":194});
															thumbnails[2485194] = clik.newPhoto({"id":2485194,"src":"_SHI1910a_thumb.jpg","galleries_id":131139,"server_id":18,"link":"photo_2485194.html","width":130,"caption":"Monique","height":194});
															thumbnails[363218] = clik.newPhoto({"id":363218,"src":"piggy_001_thumb.jpg","galleries_id":29564,"server_id":18,"link":"photo_363218.html","width":130,"caption":"this little piggy goes to market","height":87});
															thumbnails[1973891] = clik.newPhoto({"id":1973891,"src":"RachelLouise016_thumb.jpg","galleries_id":131139,"server_id":18,"link":"photo_1973891.html","width":130,"caption":"Rachel Louise","height":194});
															thumbnails[8934526] = clik.newPhoto({"id":8934526,"src":"The_Langdale_Pikes_from_the_valley_floor._SH7_7988-Edit-2-2_6D9063AA-1EC9-DFB6-0994FCD8B9BE1B49_thumb.jpg","galleries_id":470149,"server_id":18,"link":"photo_8934526.html","width":130,"caption":"The Langdale Pikes from the valley floor. SH7 7988-Edit-2-2","height":52});
															thumbnails[8934527] = clik.newPhoto({"id":8934527,"src":"The_Langdale_Pikes_from_the_valley_floor._SH7_7988-Edit-2_6D90CC3D-1EC9-DFB6-09CA12B4573A6F61_thumb.jpg","galleries_id":470149,"server_id":18,"link":"photo_8934527.html","width":130,"caption":"The Langdale Pikes from the valley floor. SH7 7988-Edit-2","height":130});
															thumbnails[8934528] = clik.newPhoto({"id":8934528,"src":"The_Langdale_Pikes_from_the_valley_floor._SH7_7988-Edit_6D9135EC-1EC9-DFB6-094FE236ACE8353E_thumb.jpg","galleries_id":470149,"server_id":18,"link":"photo_8934528.html","width":130,"caption":"The Langdale Pikes from the valley floor. SH7 7988-Edit","height":130});
															thumbnails[1974143] = clik.newPhoto({"id":1974143,"src":"RachelLouise014_thumb.jpg","galleries_id":131139,"server_id":18,"link":"photo_1974143.html","width":130,"caption":"Rachel Louise","height":194});
															thumbnails[8934529] = clik.newPhoto({"id":8934529,"src":"The_Langdale_Pikes_from_the_valley_floor._SH7_7997-Edit-2_6D919508-1EC9-DFB6-09C0329E8FB18265_thumb.jpg","galleries_id":470149,"server_id":18,"link":"photo_8934529.html","width":130,"caption":"The Langdale Pikes from the valley floor. SH7 7997-Edit-2","height":130});
															thumbnails[1973893] = clik.newPhoto({"id":1973893,"src":"RachelLouise033_thumb.jpg","galleries_id":131139,"server_id":18,"link":"photo_1973893.html","width":130,"caption":"Rachel Louise","height":223});
															thumbnails[1974049] = clik.newPhoto({"id":1974049,"src":"Rachellouise004_thumb.jpg","galleries_id":131139,"server_id":18,"link":"photo_1974049.html","width":130,"caption":"Rachel Louise","height":194});
															thumbnails[1973925] = clik.newPhoto({"id":1973925,"src":"RachelLouise015_thumb.jpg","galleries_id":131139,"server_id":18,"link":"photo_1973925.html","width":130,"caption":"Rachel Louise","height":195});
															thumbnails[2845654] = clik.newPhoto({"id":2845654,"src":"sheep4_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_2845654.html","width":130,"caption":"","height":130});
															thumbnails[2845611] = clik.newPhoto({"id":2845611,"src":"AJH_4527_loxley_thumb.jpg","galleries_id":177211,"server_id":18,"link":"photo_2845611.html","width":130,"caption":"","height":130});
															thumbnails[1981029] = clik.newPhoto({"id":1981029,"src":"happy_birthday_greeting_card_004_thumb.jpg","galleries_id":132720,"server_id":18,"link":"photo_1981029.html","width":130,"caption":"Birthday Greetings","height":195});
															thumbnails[1982897] = clik.newPhoto({"id":1982897,"src":"happy_birthday_greeting_card_005_thumb.jpg","galleries_id":132720,"server_id":18,"link":"photo_1982897.html","width":130,"caption":"","height":86});
															thumbnails[1976500] = clik.newPhoto({"id":1976500,"src":"easter_greeting_card_001_thumb.jpg","galleries_id":132806,"server_id":18,"link":"photo_1976500.html","width":130,"caption":"Chickens at Easter","height":86});
															thumbnails[1977325] = clik.newPhoto({"id":1977325,"src":"wedding_greeting_card_001_thumb.jpg","galleries_id":132855,"server_id":18,"link":"photo_1977325.html","width":130,"caption":"Hands of the Wedding","height":86});
															thumbnails[1977344] = clik.newPhoto({"id":1977344,"src":"happy_birthday_greeting_card_001_thumb.jpg","galleries_id":132720,"server_id":18,"link":"photo_1977344.html","width":130,"caption":"Cup cakes","height":86});
															thumbnails[1982901] = clik.newPhoto({"id":1982901,"src":"christmas_greeting_card_001_thumb.jpg","galleries_id":133235,"server_id":18,"link":"photo_1982901.html","width":130,"caption":"Christmas Card from Robin Red breast","height":86});
															thumbnails[1982964] = clik.newPhoto({"id":1982964,"src":"with_sympathy_greeting_card_001_thumb.jpg","galleries_id":133236,"server_id":18,"link":"photo_1982964.html","width":130,"caption":"With Sympathy","height":195});
															thumbnails[1983014] = clik.newPhoto({"id":1983014,"src":"fathers_day_greeting_card_001_thumb.jpg","galleries_id":133237,"server_id":18,"link":"photo_1983014.html","width":130,"caption":"Fathers Day - Golf balls","height":87});
															thumbnails[1983080] = clik.newPhoto({"id":1983080,"src":"thank_you_greeting_card_001_thumb.jpg","galleries_id":133244,"server_id":18,"link":"photo_1983080.html","width":130,"caption":"Thank You","height":86});
															thumbnails[1976507] = clik.newPhoto({"id":1976507,"src":"easter_greeting_card_002_thumb.jpg","galleries_id":132806,"server_id":18,"link":"photo_1976507.html","width":130,"caption":"Chickens at Easter","height":86});
															thumbnails[1977331] = clik.newPhoto({"id":1977331,"src":"wedding_greeting_card_002_thumb.jpg","galleries_id":132855,"server_id":18,"link":"photo_1977331.html","width":130,"caption":"Wedding Card","height":86});
															thumbnails[1977345] = clik.newPhoto({"id":1977345,"src":"happy_birthday_greeting_card_002_thumb.jpg","galleries_id":132720,"server_id":18,"link":"photo_1977345.html","width":130,"caption":"Cup cakes","height":86});
															thumbnails[1982904] = clik.newPhoto({"id":1982904,"src":"christmas_greeting_card_002_thumb.jpg","galleries_id":133235,"server_id":18,"link":"photo_1982904.html","width":130,"caption":"Wishing you a merry Christmas and a happy New year","height":195});
															thumbnails[1982986] = clik.newPhoto({"id":1982986,"src":"with_sympathy_greeting_card_002_thumb.jpg","galleries_id":133236,"server_id":18,"link":"photo_1982986.html","width":130,"caption":"With Sympathy","height":87});
															thumbnails[1983019] = clik.newPhoto({"id":1983019,"src":"fathers_day_greeting_card_002_thumb.jpg","galleries_id":133237,"server_id":18,"link":"photo_1983019.html","width":130,"caption":"For a wonderful Father - Happy Fathers Day","height":87});
															thumbnails[1983125] = clik.newPhoto({"id":1983125,"src":"thank_you_greeting_card_002_thumb.jpg","galleries_id":133244,"server_id":18,"link":"photo_1983125.html","width":130,"caption":"Thank you very much","height":87});
															thumbnails[1977332] = clik.newPhoto({"id":1977332,"src":"wedding_greeting_card_003_thumb.jpg","galleries_id":132855,"server_id":18,"link":"photo_1977332.html","width":130,"caption":"Wedding card","height":195});
															thumbnails[1977390] = clik.newPhoto({"id":1977390,"src":"happy_birthday_greeting_card_003_thumb.jpg","galleries_id":132720,"server_id":18,"link":"photo_1977390.html","width":130,"caption":"","height":86});
															thumbnails[1982906] = clik.newPhoto({"id":1982906,"src":"christmas_greeting_card_003_thumb.jpg","galleries_id":133235,"server_id":18,"link":"photo_1982906.html","width":130,"caption":"Wishing you a merry Christmas and a happy New Year","height":86});
															thumbnails[1982992] = clik.newPhoto({"id":1982992,"src":"with_sympathy_greeting_card_003_thumb.jpg","galleries_id":133236,"server_id":18,"link":"photo_1982992.html","width":130,"caption":"With Sympathy","height":93});
															thumbnails[1983027] = clik.newPhoto({"id":1983027,"src":"fathers_day_greeting_card_003_thumb.jpg","galleries_id":133237,"server_id":18,"link":"photo_1983027.html","width":130,"caption":"To a great Dad - Happy Fathers Day","height":87});
															thumbnails[1983138] = clik.newPhoto({"id":1983138,"src":"thank_you_greeting_card_003_thumb.jpg","galleries_id":133244,"server_id":18,"link":"photo_1983138.html","width":130,"caption":"Thank You","height":86});
															thumbnails[1983000] = clik.newPhoto({"id":1983000,"src":"with_sympathy_greeting_card_004_thumb.jpg","galleries_id":133236,"server_id":18,"link":"photo_1983000.html","width":130,"caption":"With Sympathy - thinking of you","height":87});
															thumbnails[1983144] = clik.newPhoto({"id":1983144,"src":"thank_you_greeting_card_004_thumb.jpg","galleries_id":133244,"server_id":18,"link":"photo_1983144.html","width":130,"caption":"Thank You","height":86});
															thumbnails[1982907] = clik.newPhoto({"id":1982907,"src":"christmas_greeting_card_004_thumb.jpg","galleries_id":133235,"server_id":18,"link":"photo_1982907.html","width":130,"caption":"Season's Greeting","height":86});
															thumbnails[1982958] = clik.newPhoto({"id":1982958,"src":"christmas_greeting_card_005_thumb.jpg","galleries_id":133235,"server_id":18,"link":"photo_1982958.html","width":130,"caption":"Season's greetings","height":86});
															thumbnails[1983154] = clik.newPhoto({"id":1983154,"src":"thank_you_greeting_card_005_thumb.jpg","galleries_id":133244,"server_id":18,"link":"photo_1983154.html","width":130,"caption":"Thank you very much","height":87});

/***************************************************************************
* Create the array of Gallery objects                                      *
***************************************************************************/
var galleries = new Object();
				  						galleries[470166] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Headshots","link":"gallery_470166.html","maxRecords":0.0,"photoIDs":[8934725.0,8934726.0,8934727.0,8934728.0,8934729.0,8934731.0,8934732.0],"skipIndex":0,"section_code":"gallery","featured_images":"8934732,8934731,8934728,8934727,8934726,8934725","id":470166,"singleSection":false});				  						galleries[131139] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Portraits","link":"gallery_131139.html","maxRecords":0.0,"photoIDs":[2485258.0,2485251.0,2485233.0,2485222.0,2485203.0,2485228.0,2485194.0,1973891.0,1974143.0,1973893.0,1974049.0,1973925.0],"skipIndex":0,"section_code":"gallery","featured_images":"2485258,2485251,2485233,2485228,2485222,2485203,2485194,1974143,1974049,1973893,1973891","id":131139,"singleSection":false});				  						galleries[470167] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Vogue Italia","link":"gallery_470167.html","maxRecords":0.0,"photoIDs":[8934735.0,8934736.0],"skipIndex":0,"section_code":"gallery","featured_images":8934735.0,"id":470167,"singleSection":false});				  						galleries[132806] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Easter","link":"section172150_132806.html","maxRecords":0.0,"photoIDs":[1976500.0,1976507.0],"skipIndex":0,"section_code":"section172150","featured_images":"1976507,1976500","id":132806,"singleSection":false});				  						galleries[177211] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"English Countryside","link":"gallery_177211.html","maxRecords":0.0,"photoIDs":[3039621.0,3039605.0,1740118.0,1974514.0,3039310.0,3039334.0,3039619.0,3039620.0,3039610.0,3039376.0,3039311.0,3039321.0,3039317.0,3039747.0,3039316.0,3039319.0,3039384.0,3039633.0,3039313.0,3039623.0,3039379.0,3039635.0,3039615.0,3039323.0,2845600.0,2845607.0,2845652.0,2845604.0,2845601.0,2845606.0,2845651.0,3039631.0,2845609.0,1740123.0,2845648.0,2845641.0,2845654.0,2845611.0],"skipIndex":0,"section_code":"gallery","featured_images":"3039747,3039635,3039633,3039631,3039623,3039621,3039620,3039619,3039615,3039610,3039605,3039384,3039379,3039376,3039334,3039323,3039321,3039319,3039317,3039316,3039313,3039311,3039310,2845654,2845651,2845648,2845641,2845611,2845609,2845607,2845604,2845601,2845600,1974514,1740123,1740118","id":177211,"singleSection":false});				  						galleries[470149] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Lake District December 2011","link":"gallery_470149.html","maxRecords":0.0,"photoIDs":[8934517.0,8934510.0,8934518.0,8934520.0,8934521.0,8934522.0,8934524.0,8934525.0,8934526.0,8934527.0,8934528.0,8934529.0],"skipIndex":0,"section_code":"gallery","featured_images":"8934522,8934517,8934510","id":470149,"singleSection":false});				  						galleries[29536] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"London","link":"gallery_29536.html","maxRecords":0.0,"photoIDs":[521656.0,1737972.0,1737975.0,1637200.0,1637204.0,363537.0,1737962.0,1737956.0,1974539.0,1974553.0,1974560.0],"skipIndex":0,"section_code":"gallery","featured_images":"1974560,1974553,1974539,1737975,1737962,1737956,1637204,1637200,521656,363537","id":29536,"singleSection":false});				  						galleries[116887] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Bits and Pieces","link":"gallery_116887.html","maxRecords":0.0,"photoIDs":[1740136.0,1740141.0,1740144.0,1740193.0,1740127.0],"skipIndex":0,"section_code":"gallery","featured_images":"1740193,1740144,1740141,1740136,1740127","id":116887,"singleSection":false});				  						galleries[133235] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Christmas and New Year","link":"section172150_133235.html","maxRecords":0.0,"photoIDs":[1982901.0,1982904.0,1982906.0,1982907.0,1982958.0],"skipIndex":0,"section_code":"section172150","featured_images":"1982958,1982907,1982906,1982904,1982901","id":133235,"singleSection":false});				  						galleries[29567] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Birds","link":"gallery_29567.html","maxRecords":0.0,"photoIDs":[377368.0],"skipIndex":0,"section_code":"gallery","featured_images":377368.0,"id":29567,"singleSection":false});				  						galleries[29564] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Wildlife","link":"gallery_29564.html","maxRecords":0.0,"photoIDs":[2845676.0,2845666.0,2845671.0,361015.0,363192.0,363194.0,362369.0,360946.0,360939.0,363216.0,362373.0,363190.0,363218.0],"skipIndex":0,"section_code":"gallery","featured_images":"2845676,2845671,2845666,363218,363216,363194,363192,363190,362373,362369,361015,360946,360939","id":29564,"singleSection":false});				  						galleries[132720] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Happy Birthday","link":"section172150_132720.html","maxRecords":0.0,"photoIDs":[1981029.0,1982897.0,1977344.0,1977345.0,1977390.0],"skipIndex":0,"section_code":"section172150","featured_images":"1982897,1981029,1977390,1977345,1977344","id":132720,"singleSection":false});				  						galleries[133244] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Thank You Cards","link":"section172150_133244.html","maxRecords":0.0,"photoIDs":[1983080.0,1983125.0,1983138.0,1983144.0,1983154.0],"skipIndex":0,"section_code":"section172150","featured_images":"1983154,1983144,1983138,1983125,1983080","id":133244,"singleSection":false});				  						galleries[29790] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Scapes","link":"gallery_29790.html","maxRecords":0.0,"photoIDs":[2833243.0,2833234.0,2833241.0,1743753.0,2833230.0,1743754.0,1743836.0,1743757.0,1974124.0,1637218.0],"skipIndex":0,"section_code":"gallery","featured_images":"2833243,2833241,2833234,1974124,1743836,1743757,1743753","id":29790,"singleSection":false});				  						galleries[133237] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Mother's\/Father's Day cards","link":"section172150_133237.html","maxRecords":0.0,"photoIDs":[1983014.0,1983019.0,1983027.0],"skipIndex":0,"section_code":"section172150","featured_images":"1983027,1983019,1983014","id":133237,"singleSection":false});				  						galleries[132855] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Wedding Cards","link":"section172150_132855.html","maxRecords":0.0,"photoIDs":[1977325.0,1977331.0,1977332.0],"skipIndex":0,"section_code":"section172150","featured_images":"1977332,1977331,1977325","id":132855,"singleSection":false});				  						galleries[133055] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Flora","link":"gallery_133055.html","maxRecords":0.0,"photoIDs":[1637228.0,1637235.0],"skipIndex":0,"section_code":"gallery","featured_images":"1637235,1637228","id":133055,"singleSection":false});				  						galleries[133236] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"With Sympathy","link":"section172150_133236.html","maxRecords":0.0,"photoIDs":[1982964.0,1982986.0,1982992.0,1983000.0],"skipIndex":0,"section_code":"section172150","featured_images":"1983000,1982992,1982986,1982964","id":133236,"singleSection":false});/***************************************************************************
* Create the array of image sets                                           *
***************************************************************************/
var imageSets = {};
imageSets[1] = '2845676,2845671,2845666,3039621,3039605,2833243,2833241,2833234,1740118,521656,8934735,8934725,8934517,1737972,377368,361015,1974514,3039334,3039620,3039321,3039747,8934726,8934510,3039384,3039633,3039623,3039635,3039379,3039615,8934727,363194,2845607,2845600,363537,2845652,2845604,2845601,2845606,2845651,8934522,3039631,2845609,1740123,2845648,2845641,360939,363216,2845654,2845611';
imageSets[2] = '2845676,2845671,2845666,1982897,1981029,1740136,1740141,3039621,1740144,3039605,2833243,2833241,2833234,1740193,1740118,521656,8934735,8934725,8934517,1983080,1983014,1982964,1982901,1977344,1977325,1976500,1743753,1637228,377368,361015,1974514,3039334,3039310,3039619,3039620,3039610,3039376,3039311,3039321,3039747,3039317,8934726,8934510,3039316,1983125,1983019,1982986,1982904,1977345,1977331,1976507,1737975,1637235,363192,3039319,3039384,3039633,3039623,3039313,3039635,3039379,3039615,8934727,1983138,1983027,1982992,1982906,1977390,1977332,1743836,1740127,1637200,363194,8934728,1983144,1983000,1743757,1637204,362369,3039323,2845607,2845600,1983154,1982958,1982907,1974124,363537,2845604,2845601,2845651,8934731,8934522,3039631,2845609,1737962,360946,1740123,2845648,2845641,1737956,8934732,1974539,360939,363216,1974553,362373,1974560,363190,2485258,2485251,2485233,2485222,2485203,2485228,2485194,1973891,363218,1974143,1973893,1974049,2845654,2845611';
imageSets[3] = '8934735,8934725';
 /***************************************************************************
* Get a server path given an ID                                            *
***************************************************************************/
function getServerPath(server_id) {
	var val = -1;
		switch (server_id) {
		case 51:
		val = 'http://www12.clikpic.com/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 0:
		val = 'http://www.clikpic.com/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 1:
		val = 'http://www1.clikpic.com/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 2:
		val = 'http://admin.clikpic.com/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 24:
		val = 'http://tpc15/clikpic/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 4:
		val = 'http://clikchurch.clikpic.com/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 5:
		val = 'http://www2.clikpic.com/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 22:
		val = 'http://tpc5/clikpic/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 23:
		val = 'http://tpc10/clikpic/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 25:
		val = 'http://tpc16/clikpic/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 26:
		val = 'http://tpc20/clikpic/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 40:
		val = 'http://www11.clikpic.com/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 42:
		val = 'db2.clikpic.com/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 15:
		val = 'http://www3.clikpic.com/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 18:
		val = 'http://www4.clikpic.com/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 19:
		val = 'http://www5.clikpic.com/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 31:
		val = 'http://www7.clikpic.com/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 32:
		val = 'http://www8.clikpic.com/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 34:
		val = 'http://www9.clikpic.com/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 35:
		val = 'http://admin3.clikpic.com/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 37:
		val = 'http://admin4.clikpic.com/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 38:
		val = 'http://admin5.clikpic.com/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 39:
		val = 'http://www10.clikpic.com/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 53:
		val = 'http://images.clikpic.com/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 52:
		val = 'http://tpc22/clikpic/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 21:
		val = 'http://www6.clikpic.com/shaunhodge/images';
		break;
	}
		switch (server_id) {
		case 50:
		val = '[cliktext value=article.servers_id type=servers_id]/shaunhodge/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 = 'Hodge Images: ' + 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="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 += '<form id="paymentForm" style="margin:0px;border:0px;" name="paymentForm" target="_blank" action="https://www.paypal.com/cgi-bin/webscr" method="post">';
			temp += '<input type="hidden" name="item_name" value="'+item_name+'">';
			ref = '';
			if(this.photo_ref != ''){
				ref = this.photo_ref+' - '+this.caption;
			}
			else{
				ref = this.id+' - '+this.caption;
			}
			price = amount;								temp += '<input type="hidden" name="cmd" value="_cart">';
					temp += '<input type="hidden" name="business" value="hodgeimaging@hodge.me.uk">';
					temp += '<input type="hidden" name="currency_code" value="GBP">';
					temp += '<input type="hidden" name="add" value="1">';
													temp += '<input type="hidden" name="amount" value="'+amount+'">';
					temp += '<input type="hidden" name="item_number" value="'+ref+'">';
													temp += '<input type=\"Submit\" value=\"Add to cart\" id=\"paymentAddButton\" class=\"button\" onmouseover=\"this.className=\'buttonHi\';\" onmouseout=\"this.className=\'button\';\">';
										temp += '</form>';
										temp += '<form id="paymentCartForm" style="margin:0px;" name="paymentCartForm" target="_blank" action="https://www.paypal.com/cgi-bin/webscr" method="post">';
				temp += '<input type="hidden" name="cmd" value="_cart">';
				temp += '<input type="hidden" name="business" value="hodgeimaging@hodge.me.uk">';
				temp += '<input type="hidden" name="display" value="1">';
				temp += '<input type=\"Submit\" value=\"View cart\" id=\"paymentViewButton\" class=\"button\" onmouseover=\"this.className=\'buttonHi\';\" onmouseout=\"this.className=\'button\';\">';
				temp += '</form>';
						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;
	}
}

			

