window.thumbnails = {};
															thumbnails[4304217] = clik.newPhoto({"id":4304217,"src":"sand_dunes_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":130,"caption":"Sand Dunes","height":130});
															thumbnails[4359691] = clik.newPhoto({"id":4359691,"src":"1_frosty_morning_035_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":130,"caption":"Frosty morning","height":130});
															thumbnails[4359692] = clik.newPhoto({"id":4359692,"src":"2_snowmen_on_the_downs__bridge_043_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":130,"caption":"Snow people with dog","height":130});
															thumbnails[4359697] = clik.newPhoto({"id":4359697,"src":"3_perpignan_093_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":130,"caption":"Spanish Quarter","height":130});
															thumbnails[4359699] = clik.newPhoto({"id":4359699,"src":"4_032_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":130,"caption":"Street Performers","height":130});
															thumbnails[4359701] = clik.newPhoto({"id":4359701,"src":"5_brolly_street_entertainers_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":130,"caption":"Street Entertainers","height":130});
															thumbnails[4359703] = clik.newPhoto({"id":4359703,"src":"6_umbrella_tree_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":130,"caption":"Umbrella Tree","height":130});
															thumbnails[4359706] = clik.newPhoto({"id":4359706,"src":"7__thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":130,"caption":"Fan Dancer","height":130});
															thumbnails[4359708] = clik.newPhoto({"id":4359708,"src":"8_keda_breeze_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":130,"caption":"Keda Breeze","height":130});
															thumbnails[4359711] = clik.newPhoto({"id":4359711,"src":"9_saw_player_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":130,"caption":"Saw player","height":130});
															thumbnails[4359714] = clik.newPhoto({"id":4359714,"src":"10_tooth_fairy_thumb.jpg","galleries_id":"","server_id":1,"link":"#","width":130,"caption":"The Tooth Fairy","height":130});
															thumbnails[4304213] = clik.newPhoto({"id":4304213,"src":"ballet_feet_thumb.jpg","galleries_id":253732,"server_id":1,"link":"photo_4304213.html","width":130,"caption":"Ballet Bristol","height":130});
															thumbnails[4359204] = clik.newPhoto({"id":4359204,"src":"ballet_bristol_2_354_grey_copy_thumb.jpg","galleries_id":253732,"server_id":1,"link":"photo_4359204.html","width":130,"caption":"Ballet Bristol","height":130});
															thumbnails[4489733] = clik.newPhoto({"id":4489733,"src":"ballet_bristol_at_school_of_dance_016_thumb.JPG","galleries_id":253732,"server_id":1,"link":"photo_4489733.html","width":130,"caption":"Ballet Bristol","height":130});
															thumbnails[4489737] = clik.newPhoto({"id":4489737,"src":"ballet_bristol_at_school_of_dance_117_thumb.JPG","galleries_id":253732,"server_id":1,"link":"photo_4489737.html","width":130,"caption":"Ballet Bristol","height":130});
															thumbnails[4489744] = clik.newPhoto({"id":4489744,"src":"ballet_bristol_at_school_of_dance_198_thumb.JPG","galleries_id":253732,"server_id":1,"link":"photo_4489744.html","width":130,"caption":"Ballet Bristol","height":130});
															thumbnails[4489752] = clik.newPhoto({"id":4489752,"src":"ballet_bristol_at_school_of_dance_208_thumb.JPG","galleries_id":253732,"server_id":1,"link":"photo_4489752.html","width":130,"caption":"Ballet Bristol","height":130});
															thumbnails[4489758] = clik.newPhoto({"id":4489758,"src":"ballet_bristol_at_school_of_dance_421_thumb.JPG","galleries_id":253732,"server_id":1,"link":"photo_4489758.html","width":130,"caption":"Ballet Bristol","height":130});
															thumbnails[4489760] = clik.newPhoto({"id":4489760,"src":"ballet_bristol_at_school_of_dance_427_thumb.JPG","galleries_id":253732,"server_id":1,"link":"photo_4489760.html","width":130,"caption":"Ballet Bristol","height":130});
															thumbnails[4489767] = clik.newPhoto({"id":4489767,"src":"ballet_bristol_at_school_of_dance_442_thumb.JPG","galleries_id":253732,"server_id":1,"link":"photo_4489767.html","width":130,"caption":"Ballet Bristol","height":130});
															thumbnails[6564209] = clik.newPhoto({"id":6564209,"src":"ballet_bristol_Degas_shoot_058_thumb.jpg","galleries_id":253732,"server_id":1,"link":"photo_6564209.html","width":130,"caption":"Ballerinas","height":130});
															thumbnails[6564212] = clik.newPhoto({"id":6564212,"src":"ballet_bristol_Degas_shoot_118_thumb.jpg","galleries_id":253732,"server_id":1,"link":"photo_6564212.html","width":130,"caption":"Ballerinas","height":130});
															thumbnails[7806936] = clik.newPhoto({"id":7806936,"src":"3_ballerinas_RGB_1_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_7806936.html","width":130,"caption":"3 Ballerinas Tying pointe Shoes","height":130});
															thumbnails[7806950] = clik.newPhoto({"id":7806950,"src":"The_Ballet_lesson_RGB_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_7806950.html","width":130,"caption":"The Ballet Lesson","height":130});
															thumbnails[8868947] = clik.newPhoto({"id":8868947,"src":"WINK_thumb.jpg","galleries_id":407961,"server_id":1,"link":"photo_8868947.html","width":130,"caption":"Wink","height":130});
															thumbnails[8868950] = clik.newPhoto({"id":8868950,"src":"BLONDE_BOMBSHELL_thumb.jpg","galleries_id":407961,"server_id":1,"link":"photo_8868950.html","width":130,"caption":"Blonde Bombshell","height":130});
															thumbnails[8869267] = clik.newPhoto({"id":8869267,"src":"BURLESQUE_PORTRAIT_CARDS_2_thumb.jpg","galleries_id":466481,"server_id":1,"link":"photo_8869267.html","width":130,"caption":"Hoochie-Coochie Xmas","height":130});
															thumbnails[8869840] = clik.newPhoto({"id":8869840,"src":"golden_ticket_thumb.jpg","galleries_id":407961,"server_id":1,"link":"photo_8869840.html","width":130,"caption":"Golden ticket","height":130});
															thumbnails[8869846] = clik.newPhoto({"id":8869846,"src":"WINK_FD39898A-1EC9-D45B-1C587FF1F68BE897_thumb.jpg","galleries_id":466481,"server_id":1,"link":"photo_8869846.html","width":130,"caption":"Wink!","height":130});
															thumbnails[8869848] = clik.newPhoto({"id":8869848,"src":"BLONDE_BOMBSHELL_FD3F410E-1EC9-D45B-1CF7776412948005_thumb.jpg","galleries_id":466481,"server_id":1,"link":"photo_8869848.html","width":130,"caption":"Blonde Bombshell","height":130});
															thumbnails[8900227] = clik.newPhoto({"id":8900227,"src":"trapeze_thumb.jpg","galleries_id":466481,"server_id":1,"link":"photo_8900227.html","width":130,"caption":"Trapeze Artiste","height":130});
															thumbnails[8900236] = clik.newPhoto({"id":8900236,"src":"trapeze_2_52183F61-1EC9-D45B-1C9AA2628978EB6D_thumb.jpg","galleries_id":407961,"server_id":1,"link":"photo_8900236.html","width":130,"caption":"Trapeze Artiste","height":130});
															thumbnails[9008186] = clik.newPhoto({"id":9008186,"src":"corset_90960C55-1EC9-DFB6-09EF8FC7DBD2B5B8_thumb.jpg","galleries_id":466481,"server_id":1,"link":"photo_9008186.html","width":130,"caption":"Breathe in, Ouch!","height":130});
															thumbnails[9083773] = clik.newPhoto({"id":9083773,"src":"IMG_9394_thumb.jpg","galleries_id":362129,"server_id":1,"link":"photo_9083773.html","width":130,"caption":"","height":130});
															thumbnails[9083785] = clik.newPhoto({"id":9083785,"src":"IMG_9395_thumb.jpg","galleries_id":362129,"server_id":1,"link":"photo_9083785.html","width":130,"caption":"","height":130});
															thumbnails[9083793] = clik.newPhoto({"id":9083793,"src":"IMG_9424_thumb.jpg","galleries_id":362129,"server_id":1,"link":"photo_9083793.html","width":130,"caption":"","height":130});
															thumbnails[9083799] = clik.newPhoto({"id":9083799,"src":"IMG_9425_thumb.jpg","galleries_id":362129,"server_id":1,"link":"photo_9083799.html","width":130,"caption":"","height":130});
															thumbnails[9083808] = clik.newPhoto({"id":9083808,"src":"IMG_9426_thumb.jpg","galleries_id":362129,"server_id":1,"link":"photo_9083808.html","width":130,"caption":"","height":130});
															thumbnails[9083836] = clik.newPhoto({"id":9083836,"src":"IMG_9427_thumb.JPG","galleries_id":362129,"server_id":1,"link":"photo_9083836.html","width":130,"caption":"","height":130});
															thumbnails[9083844] = clik.newPhoto({"id":9083844,"src":"IMG_9439_thumb.jpg","galleries_id":362129,"server_id":1,"link":"photo_9083844.html","width":130,"caption":"","height":130});
															thumbnails[9083851] = clik.newPhoto({"id":9083851,"src":"IMG_9440_thumb.jpg","galleries_id":362129,"server_id":1,"link":"photo_9083851.html","width":130,"caption":"","height":130});
															thumbnails[9083856] = clik.newPhoto({"id":9083856,"src":"IMG_9442_thumb.jpg","galleries_id":362129,"server_id":1,"link":"photo_9083856.html","width":130,"caption":"","height":130});
															thumbnails[9083862] = clik.newPhoto({"id":9083862,"src":"IMG_9454_thumb.jpg","galleries_id":362129,"server_id":1,"link":"photo_9083862.html","width":130,"caption":"","height":130});
															thumbnails[9083867] = clik.newPhoto({"id":9083867,"src":"IMG_9457_1_thumb.jpg","galleries_id":362129,"server_id":1,"link":"photo_9083867.html","width":130,"caption":"","height":130});
															thumbnails[387020] = clik.newPhoto({"id":387020,"src":"catching_a_crab341x235_thumb.jpg","galleries_id":195964,"server_id":1,"link":"photo_387020.html","width":130,"caption":"Catching a Crab","height":130});
															thumbnails[389656] = clik.newPhoto({"id":389656,"src":"gathering_seashells342x162_thumb.jpg","galleries_id":195964,"server_id":1,"link":"photo_389656.html","width":130,"caption":"Gathering seashells","height":130});
															thumbnails[389694] = clik.newPhoto({"id":389694,"src":"summer_breeze_267x197_thumb.jpg","galleries_id":195964,"server_id":1,"link":"photo_389694.html","width":130,"caption":"Summer breeze","height":130});
															thumbnails[695768] = clik.newPhoto({"id":695768,"src":"holding_back_the_tide331x220_thumb.jpg","galleries_id":195964,"server_id":1,"link":"photo_695768.html","width":130,"caption":"Holding back the tide","height":130});
															thumbnails[695769] = clik.newPhoto({"id":695769,"src":"rockpool_308x215_thumb.jpg","galleries_id":195964,"server_id":1,"link":"photo_695769.html","width":130,"caption":"Rockpool","height":130});
															thumbnails[1541410] = clik.newPhoto({"id":1541410,"src":"going_fishing363x244_thumb.jpg","galleries_id":195964,"server_id":1,"link":"photo_1541410.html","width":130,"caption":"Going Fishing, Port Isaac, Cornwall","height":130});
															thumbnails[2123654] = clik.newPhoto({"id":2123654,"src":"running_to_the_sea_354x244_thumb.jpg","galleries_id":195964,"server_id":1,"link":"photo_2123654.html","width":130,"caption":"Running to the sea","height":130});
															thumbnails[3239432] = clik.newPhoto({"id":3239432,"src":"issy_fowey_366X243_thumb.jpg","galleries_id":195964,"server_id":1,"link":"photo_3239432.html","width":130,"caption":"Low tide at Fowey, Cornwall","height":130});
															thumbnails[3832348] = clik.newPhoto({"id":3832348,"src":"sisters2_thumb.jpg","galleries_id":195964,"server_id":1,"link":"photo_3832348.html","width":130,"caption":"Sisters","height":130});
															thumbnails[4205702] = clik.newPhoto({"id":4205702,"src":"boys_bucket_square_thumb.jpg","galleries_id":195964,"server_id":1,"link":"photo_4205702.html","width":130,"caption":"Brothers on the beach","height":130});
															thumbnails[4359201] = clik.newPhoto({"id":4359201,"src":"065_thumb.jpg","galleries_id":253732,"server_id":1,"link":"photo_4359201.html","width":130,"caption":"Ballet Bristol","height":130});
															thumbnails[4552341] = clik.newPhoto({"id":4552341,"src":"laura_in_blue_lo_res_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_4552341.html","width":130,"caption":"Classic Dying Swan","height":130});
															thumbnails[6318640] = clik.newPhoto({"id":6318640,"src":"beachcombing330x220_thumb.jpg","galleries_id":195964,"server_id":1,"link":"photo_6318640.html","width":130,"caption":"Beachcombing","height":130});
															thumbnails[6321749] = clik.newPhoto({"id":6321749,"src":"child_washing_feet339x234_thumb.jpg","galleries_id":195964,"server_id":1,"link":"photo_6321749.html","width":130,"caption":"Child washing feet","height":130});
															thumbnails[6321750] = clik.newPhoto({"id":6321750,"src":"dusk_on_verandah330_x216_thumb.jpg","galleries_id":195964,"server_id":1,"link":"photo_6321750.html","width":130,"caption":"Dusk on the verandah","height":130});
															thumbnails[6321753] = clik.newPhoto({"id":6321753,"src":"footsteps_to_sea220x220_thumb.jpg","galleries_id":195964,"server_id":1,"link":"photo_6321753.html","width":130,"caption":"Footsteps to the sea","height":130});
															thumbnails[6321757] = clik.newPhoto({"id":6321757,"src":"holding_hands_sunset327x238_thumb.jpg","galleries_id":195964,"server_id":1,"link":"photo_6321757.html","width":130,"caption":"Holding hands, Polzeath, Cornwall","height":130});
															thumbnails[6564197] = clik.newPhoto({"id":6564197,"src":"ballet_bristol_Degas_shoot_049_thumb.jpg","galleries_id":253732,"server_id":1,"link":"photo_6564197.html","width":130,"caption":"Ballerinas","height":130});
															thumbnails[6564206] = clik.newPhoto({"id":6564206,"src":"ballet_bristol_Degas_shoot_050_thumb.jpg","galleries_id":253732,"server_id":1,"link":"photo_6564206.html","width":130,"caption":"Ballerinas","height":130});
															thumbnails[6564213] = clik.newPhoto({"id":6564213,"src":"IMG_7116_thumb.jpg","galleries_id":253732,"server_id":1,"link":"photo_6564213.html","width":130,"caption":"At the barre","height":130});
															thumbnails[6610009] = clik.newPhoto({"id":6610009,"src":"underwater_thumb.jpg","galleries_id":362129,"server_id":1,"link":"photo_6610009.html","width":130,"caption":"Nude swimming I","height":130});
															thumbnails[6610010] = clik.newPhoto({"id":6610010,"src":"swimming_nude_II_thumb.jpg","galleries_id":362129,"server_id":1,"link":"photo_6610010.html","width":130,"caption":"Nude swimming II","height":130});
															thumbnails[6610011] = clik.newPhoto({"id":6610011,"src":"ballet_commission_1_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_6610011.html","width":130,"caption":"Dancer at the barre, study","height":130});
															thumbnails[6610012] = clik.newPhoto({"id":6610012,"src":"ballet_commission_2_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_6610012.html","width":130,"caption":"dancer rehearsing, tonal study","height":130});
															thumbnails[7645386] = clik.newPhoto({"id":7645386,"src":"terracotta_ballerina_tying_shoes_x2_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_7645386.html","width":130,"caption":"Tying pointe shoes","height":133});
															thumbnails[7645393] = clik.newPhoto({"id":7645393,"src":"terracotta_ballerina_pose_x3_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_7645393.html","width":130,"caption":"Ballerina pose","height":135});
															thumbnails[7949091] = clik.newPhoto({"id":7949091,"src":"lyme_regis1_thumb.jpg","galleries_id":407961,"server_id":1,"link":"photo_7949091.html","width":130,"caption":"Beach Huts, Lyme Regis","height":130});
															thumbnails[8029916] = clik.newPhoto({"id":8029916,"src":"new_xmas_6_thumb.jpg","galleries_id":407961,"server_id":1,"link":"photo_8029916.html","width":130,"caption":"Waiting for Santa (xmas card design)","height":130});
															thumbnails[9079710] = clik.newPhoto({"id":9079710,"src":"ballet_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_9079710.html","width":130,"caption":"The Ballet Class","height":130});
															thumbnails[9079711] = clik.newPhoto({"id":9079711,"src":"IMG_9455_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_9079711.html","width":130,"caption":"Ballerinas relaxing","height":130});
															thumbnails[386383] = clik.newPhoto({"id":386383,"src":"summer walk1.jpg","galleries_id":364177,"server_id":1,"link":"photo_386383.html","width":130,"caption":"Summer Walk","height":130});
															thumbnails[598128] = clik.newPhoto({"id":598128,"src":"home-from-the-park1.jpg","galleries_id":364177,"server_id":1,"link":"photo_598128.html","width":130,"caption":"Home from the Park","height":139});
															thumbnails[643470] = clik.newPhoto({"id":643470,"src":"tea_in_the_park_312x230_thumb.jpg","galleries_id":364177,"server_id":1,"link":"photo_643470.html","width":130,"caption":"Tea in the Park","height":130});
															thumbnails[672106] = clik.newPhoto({"id":672106,"src":"skating in cenral park3.jpg","galleries_id":350472,"server_id":1,"link":"photo_672106.html","width":130,"caption":"Skating in Central Park, New York.","height":130});
															thumbnails[818437] = clik.newPhoto({"id":818437,"src":"weeding_the_allotment_345x180_thumb.jpg","galleries_id":364177,"server_id":1,"link":"photo_818437.html","width":130,"caption":"Weeding the Allotment","height":130});
															thumbnails[818441] = clik.newPhoto({"id":818441,"src":"working_on_the_allotment_341x183__thumb.jpg","galleries_id":364177,"server_id":1,"link":"photo_818441.html","width":130,"caption":"Working on the Allotment","height":130});
															thumbnails[1278473] = clik.newPhoto({"id":1278473,"src":"fishermen_gozo363x244_thumb.jpg","galleries_id":195964,"server_id":1,"link":"photo_1278473.html","width":130,"caption":"Fishermen, Island of Gozo, Near Malta","height":130});
															thumbnails[1394902] = clik.newPhoto({"id":1394902,"src":"medina_malta_329X239_thumb.jpg","galleries_id":364177,"server_id":1,"link":"photo_1394902.html","width":130,"caption":"Bus stop, Medina, Malta","height":130});
															thumbnails[1804064] = clik.newPhoto({"id":1804064,"src":"fishing_for_minnows_thumb.jpg","galleries_id":364177,"server_id":1,"link":"photo_1804064.html","width":130,"caption":"Fishing for minnows, Late summer ","height":130});
															thumbnails[2209407] = clik.newPhoto({"id":2209407,"src":"little_maltese_town_thumb.jpg","galleries_id":364177,"server_id":1,"link":"photo_2209407.html","width":130,"caption":"Little Maltese Town","height":130});
															thumbnails[3080402] = clik.newPhoto({"id":3080402,"src":"nice_thumb.jpg","galleries_id":350472,"server_id":1,"link":"photo_3080402.html","width":130,"caption":"Skating in Nice, Christmas Day 2007","height":130});
															thumbnails[4359202] = clik.newPhoto({"id":4359202,"src":"157_thumb.jpg","galleries_id":253732,"server_id":1,"link":"photo_4359202.html","width":130,"caption":"Ballet Bristol","height":130});
															thumbnails[4572137] = clik.newPhoto({"id":4572137,"src":"laura_3_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_4572137.html","width":130,"caption":"Ballerina tying pointe shoes","height":130});
															thumbnails[6318647] = clik.newPhoto({"id":6318647,"src":"billie_jean365x167_thumb.jpg","galleries_id":364177,"server_id":1,"link":"photo_6318647.html","width":130,"caption":"Billie Jean clothes shop","height":130});
															thumbnails[6321748] = clik.newPhoto({"id":6321748,"src":"cafe_in_the_rain353x263_thumb.jpg","galleries_id":364177,"server_id":1,"link":"photo_6321748.html","width":130,"caption":"Cafe in the rain, Nice","height":130});
															thumbnails[6321760] = clik.newPhoto({"id":6321760,"src":"Prom_music_cafe_print_353x157_thumb.jpg","galleries_id":364177,"server_id":1,"link":"photo_6321760.html","width":130,"caption":"Prom music cafe","height":130});
															thumbnails[1948841] = clik.newPhoto({"id":1948841,"src":"nude_lying_378X214_thumb.jpg","galleries_id":362129,"server_id":1,"link":"photo_1948841.html","width":130,"caption":"Nude reclining","height":130});
															thumbnails[1949202] = clik.newPhoto({"id":1949202,"src":"tub_thumb.jpg","galleries_id":362129,"server_id":1,"link":"photo_1949202.html","width":130,"caption":"Copy of Degas' Women Bathing","height":130});
															thumbnails[2022118] = clik.newPhoto({"id":2022118,"src":"nude_before_the_bath_353X237_thumb.jpg","galleries_id":362129,"server_id":1,"link":"photo_2022118.html","width":130,"caption":"Before the Bath by Candlelight","height":130});
															thumbnails[3796276] = clik.newPhoto({"id":3796276,"src":"swan_lake_hands_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_3796276.html","width":130,"caption":"Swan Lake, Hands","height":133});
															thumbnails[4359203] = clik.newPhoto({"id":4359203,"src":"181_thumb.jpg","galleries_id":253732,"server_id":1,"link":"photo_4359203.html","width":130,"caption":"Ballet Bristol","height":130});
															thumbnails[6327145] = clik.newPhoto({"id":6327145,"src":"CHR1_snowgirl_thumb.jpg","galleries_id":350472,"server_id":1,"link":"photo_6327145.html","width":130,"caption":"Snow girl","height":130});
															thumbnails[7850722] = clik.newPhoto({"id":7850722,"src":"ballerina_kneeling_thumb.jpg","galleries_id":407961,"server_id":1,"link":"photo_7850722.html","width":130,"caption":"Ballerina kneeling","height":130});
															thumbnails[999683] = clik.newPhoto({"id":999683,"src":"hugh_coakham_thumb.jpg","galleries_id":364177,"server_id":1,"link":"photo_999683.html","width":130,"caption":"Professor Hugh Coakham","height":130});
															thumbnails[1060968] = clik.newPhoto({"id":1060968,"src":"kate_thumb.jpg","galleries_id":364177,"server_id":1,"link":"photo_1060968.html","width":130,"caption":"Kate","height":130});
															thumbnails[4892024] = clik.newPhoto({"id":4892024,"src":"ballet_arms_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_4892024.html","width":130,"caption":"Graceful arms","height":130});
															thumbnails[6327185] = clik.newPhoto({"id":6327185,"src":"CHR2_fun_in_the_snow_thumb.jpg","galleries_id":350472,"server_id":1,"link":"photo_6327185.html","width":130,"caption":"Fun in the snow","height":130});
															thumbnails[6338752] = clik.newPhoto({"id":6338752,"src":"amnic_wide_thumb.jpg","galleries_id":364177,"server_id":1,"link":"photo_6338752.html","width":130,"caption":"Amnic","height":130});
															thumbnails[6686086] = clik.newPhoto({"id":6686086,"src":"nude_1_001_thumb.JPG","galleries_id":362129,"server_id":1,"link":"photo_6686086.html","width":130,"caption":"Life study","height":130});
															thumbnails[6794149] = clik.newPhoto({"id":6794149,"src":"framed_nude_012_thumb.JPG","galleries_id":362129,"server_id":1,"link":"photo_6794149.html","width":130,"caption":"Life study","height":130});
															thumbnails[2834217] = clik.newPhoto({"id":2834217,"src":"Burlesque_legs_thumb.jpg","galleries_id":466481,"server_id":1,"link":"photo_2834217.html","width":130,"caption":"Burlesque dancer","height":130});
															thumbnails[3893427] = clik.newPhoto({"id":3893427,"src":"tired_dancers_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_3893427.html","width":130,"caption":"Ballerinas resting","height":130});
															thumbnails[4359205] = clik.newPhoto({"id":4359205,"src":"ballet_class_grey_thumb.jpg","galleries_id":253732,"server_id":1,"link":"photo_4359205.html","width":130,"caption":"Bristol College of Dance","height":130});
															thumbnails[4601605] = clik.newPhoto({"id":4601605,"src":"hp_scanDS_98279525129_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_4601605.html","width":130,"caption":"Attitude derriere","height":130});
															thumbnails[6335690] = clik.newPhoto({"id":6335690,"src":"CHR3_snow_man_thumb.jpg","galleries_id":350472,"server_id":1,"link":"photo_6335690.html","width":130,"caption":"Snowman","height":130});
															thumbnails[6662702] = clik.newPhoto({"id":6662702,"src":"burlesque_twirl_clikpic_thumb.jpg","galleries_id":466481,"server_id":1,"link":"photo_6662702.html","width":130,"caption":"Burlesque twirl","height":130});
															thumbnails[7249604] = clik.newPhoto({"id":7249604,"src":"Three_ballerinas_tying_pointe_shoes_x4_thumb.jpg","galleries_id":407961,"server_id":1,"link":"photo_7249604.html","width":130,"caption":"Tying pointe shoes ","height":130});
															thumbnails[7294029] = clik.newPhoto({"id":7294029,"src":"annabelle_thumb.jpg","galleries_id":364177,"server_id":1,"link":"photo_7294029.html","width":130,"caption":"Annabelle's first train journey","height":130});
															thumbnails[4359206] = clik.newPhoto({"id":4359206,"src":"bristol_school_of_dancing_025_thumb.jpg","galleries_id":253732,"server_id":1,"link":"photo_4359206.html","width":130,"caption":"Bristol College of Dance","height":130});
															thumbnails[5363689] = clik.newPhoto({"id":5363689,"src":"giselle_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_5363689.html","width":130,"caption":"Crystal Costa & Daniel Kraus, English National Ballet","height":130});
															thumbnails[6335691] = clik.newPhoto({"id":6335691,"src":"CHR4_tired_fairies_thumb.jpg","galleries_id":350472,"server_id":1,"link":"photo_6335691.html","width":130,"caption":"Tired fairies","height":130});
															thumbnails[6335693] = clik.newPhoto({"id":6335693,"src":"CHR10_snow_st_andrews_thumb.jpg","galleries_id":350472,"server_id":1,"link":"photo_6335693.html","width":130,"caption":"Snow in the park","height":130});
															thumbnails[7562819] = clik.newPhoto({"id":7562819,"src":"the_ballet_lesson_x2_thumb.jpg","galleries_id":407961,"server_id":1,"link":"photo_7562819.html","width":130,"caption":"The Ballet lesson","height":130});
															thumbnails[4359207] = clik.newPhoto({"id":4359207,"src":"bristol_school_of_dancing_065_thumb.jpg","galleries_id":253732,"server_id":1,"link":"photo_4359207.html","width":130,"caption":"Brsitol College of Dance","height":130});
															thumbnails[4382283] = clik.newPhoto({"id":4382283,"src":"dancers_tying_shoes_copy_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_4382283.html","width":130,"caption":"Tying of Pointe shoes","height":130});
															thumbnails[6519141] = clik.newPhoto({"id":6519141,"src":"CHR7_sledging_before_school_thumb.jpg","galleries_id":350472,"server_id":1,"link":"photo_6519141.html","width":130,"caption":"Sledging before school","height":131});
															thumbnails[386238] = clik.newPhoto({"id":386238,"src":"dancer1.jpg","galleries_id":230952,"server_id":1,"link":"photo_386238.html","width":130,"caption":"Dancer tying pointe shoes","height":130});
															thumbnails[4359209] = clik.newPhoto({"id":4359209,"src":"ballet_rehearsal_thumb.jpg","galleries_id":253732,"server_id":1,"link":"photo_4359209.html","width":130,"caption":"Bristol College of Dance","height":130});
															thumbnails[7838388] = clik.newPhoto({"id":7838388,"src":"bob_in_nice_grey_173EA598-24E8-5EC4-4F4C46F89D3B444A_thumb.jpg","galleries_id":423018,"server_id":1,"link":"photo_7838388.html","width":130,"caption":"Robert Antell, Pastel Artist","height":130});
															thumbnails[4359210] = clik.newPhoto({"id":4359210,"src":"bristol_school_of_dancing_114_thumb.jpg","galleries_id":253732,"server_id":1,"link":"photo_4359210.html","width":130,"caption":"Brsitol College of Dance","height":130});
															thumbnails[4552336] = clik.newPhoto({"id":4552336,"src":"young_ballerina_1_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_4552336.html","width":130,"caption":"Young ballerina resting","height":130});
															thumbnails[3832377] = clik.newPhoto({"id":3832377,"src":"laura_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_3832377.html","width":130,"caption":"Ballerina tying pointe shoes","height":130});
															thumbnails[4359211] = clik.newPhoto({"id":4359211,"src":"IMG_8031_thumb.jpg","galleries_id":253732,"server_id":1,"link":"photo_4359211.html","width":130,"caption":"Ballet Bristol","height":130});
															thumbnails[6335695] = clik.newPhoto({"id":6335695,"src":"GAR4_flying_a_kite_thumb.jpg","galleries_id":350472,"server_id":1,"link":"photo_6335695.html","width":130,"caption":"Flying a kite","height":130});
															thumbnails[7294024] = clik.newPhoto({"id":7294024,"src":"anna_dancing_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_7294024.html","width":130,"caption":"Little ballerina","height":131});
															thumbnails[4359212] = clik.newPhoto({"id":4359212,"src":"IMG_8035_thumb.jpg","galleries_id":253732,"server_id":1,"link":"photo_4359212.html","width":130,"caption":"Ballet Bristol","height":130});
															thumbnails[1981126] = clik.newPhoto({"id":1981126,"src":"degas clikpic_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_1981126.html","width":130,"caption":"Copy of Degas' Blue Dancers","height":128});
															thumbnails[4359213] = clik.newPhoto({"id":4359213,"src":"IMG_8226_thumb.jpg","galleries_id":253732,"server_id":1,"link":"photo_4359213.html","width":130,"caption":"Ballet Bristol","height":130});
															thumbnails[6321759] = clik.newPhoto({"id":6321759,"src":"mother_and_baby_309X206_thumb.jpg","galleries_id":350472,"server_id":1,"link":"photo_6321759.html","width":130,"caption":"New baby","height":130});
															thumbnails[6335716] = clik.newPhoto({"id":6335716,"src":"OCC4_after_the_wedding_thumb.jpg","galleries_id":350472,"server_id":1,"link":"photo_6335716.html","width":130,"caption":"After the wedding","height":130});
															thumbnails[1949201] = clik.newPhoto({"id":1949201,"src":"waiting in the wings_thumb.JPG","galleries_id":230952,"server_id":1,"link":"photo_1949201.html","width":130,"caption":"Waiting in the Wings","height":129});
															thumbnails[4359215] = clik.newPhoto({"id":4359215,"src":"IMG_82991_thumb.jpg","galleries_id":253732,"server_id":1,"link":"photo_4359215.html","width":130,"caption":"Ballet Bristol","height":130});
															thumbnails[4359220] = clik.newPhoto({"id":4359220,"src":"IMG_8379_thumb.jpg","galleries_id":253732,"server_id":1,"link":"photo_4359220.html","width":130,"caption":"Ballet Bristol","height":130});
															thumbnails[4359221] = clik.newPhoto({"id":4359221,"src":"kate_1_thumb.jpg","galleries_id":253732,"server_id":1,"link":"photo_4359221.html","width":130,"caption":"Ballet Bristol","height":130});
															thumbnails[4947264] = clik.newPhoto({"id":4947264,"src":"emily_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_4947264.html","width":130,"caption":"Pas de Dessus","height":130});
															thumbnails[4359222] = clik.newPhoto({"id":4359222,"src":"laura_2_thumb.jpg","galleries_id":253732,"server_id":1,"link":"photo_4359222.html","width":130,"caption":"Ballet Bristol","height":130});
															thumbnails[4305351] = clik.newPhoto({"id":4305351,"src":"ballet_blue_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_4305351.html","width":130,"caption":"Young Ballerina","height":130});
															thumbnails[3915606] = clik.newPhoto({"id":3915606,"src":"young_ballerina_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_3915606.html","width":130,"caption":"Young Ballerina tying shoes","height":128});
															thumbnails[7145897] = clik.newPhoto({"id":7145897,"src":"make_a_wish_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_7145897.html","width":130,"caption":"Make a wish","height":130});
															thumbnails[7419466] = clik.newPhoto({"id":7419466,"src":"boys_head_006_clikpic_thumb.jpg","galleries_id":364177,"server_id":1,"link":"photo_7419466.html","width":130,"caption":"Portrait of a young boy","height":130});
															thumbnails[7623379] = clik.newPhoto({"id":7623379,"src":"nude_thumb.jpg","galleries_id":362129,"server_id":1,"link":"photo_7623379.html","width":130,"caption":"Life study","height":130});
															thumbnails[1949193] = clik.newPhoto({"id":1949193,"src":"flower fairy_thumb.JPG","galleries_id":230952,"server_id":1,"link":"photo_1949193.html","width":130,"caption":"Young ballerina","height":132});
															thumbnails[3832768] = clik.newPhoto({"id":3832768,"src":"Ballet_Brsitol_sketch_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_3832768.html","width":130,"caption":"Ballerina tying shoes","height":130});
															thumbnails[5591774] = clik.newPhoto({"id":5591774,"src":"balet_compilation_1_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_5591774.html","width":130,"caption":"Ballerina tying pointe shoes","height":130});
															thumbnails[5143198] = clik.newPhoto({"id":5143198,"src":"ballet_poster_thumb.jpg","galleries_id":230952,"server_id":1,"link":"photo_5143198.html","width":130,"caption":"Exhibition poster","height":184});
															thumbnails[5363703] = clik.newPhoto({"id":5363703,"src":"sadie_2_thumb.jpg","galleries_id":364177,"server_id":1,"link":"photo_5363703.html","width":130,"caption":"Sadie","height":130});
															thumbnails[5587217] = clik.newPhoto({"id":5587217,"src":"Alexander_and_rosalind_2_thumb.jpg","galleries_id":364177,"server_id":1,"link":"photo_5587217.html","width":130,"caption":"Rosalind and Alexander","height":130});
															thumbnails[4482905] = clik.newPhoto({"id":4482905,"src":"crb-logo_thumb.jpg","galleries_id":319478,"server_id":1,"link":"photo_4482905.html","width":130,"caption":"Criminal Records Bureau Checked and approved.<br>\r\n","height":78});
															thumbnails[3328847] = clik.newPhoto({"id":3328847,"src":"bob_in_nice_grey_thumb.jpg","galleries_id":319478,"server_id":1,"link":"photo_3328847.html","width":130,"caption":"ARTIST BIOGRAPHY","height":130});
															thumbnails[2000995] = clik.newPhoto({"id":2000995,"src":"artist and illustrators_thumb.jpg","galleries_id":319478,"server_id":1,"link":"photo_2000995.html","width":130,"caption":"Artists & Illustrators Magazine","height":163});

/***************************************************************************
* Create the array of Gallery objects                                      *
***************************************************************************/
var galleries = new Object();
				  						galleries[319478] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"ARTIST BIOGRAPHY","link":"section383082.html","maxRecords":0.0,"photoIDs":[4482905.0,3328847.0,2000995.0],"skipIndex":0,"section_code":"section383082","featured_images":3328847.0,"id":319478,"singleSection":true});				  						galleries[230952] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Ballet Pastel Paintings, Prints ","link":"gallery_230952.html","maxRecords":0.0,"photoIDs":[7806936.0,7806950.0,4552341.0,6610011.0,6610012.0,7645386.0,7645393.0,9079710.0,9079711.0,4572137.0,3796276.0,4892024.0,3893427.0,4601605.0,5363689.0,4382283.0,386238.0,4552336.0,3832377.0,7294024.0,1981126.0,1949201.0,4947264.0,4305351.0,3915606.0,7145897.0,1949193.0,3832768.0,5591774.0,5143198.0],"skipIndex":0,"section_code":"gallery","featured_images":3832377.0,"id":230952,"singleSection":false});				  						galleries[407961] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"New work","link":"gallery_407961.html","maxRecords":0.0,"photoIDs":[8868947.0,8868950.0,8869840.0,8900236.0,7949091.0,8029916.0,7850722.0,7249604.0,7562819.0],"skipIndex":0,"section_code":"gallery","featured_images":"8868950,7949091","id":407961,"singleSection":false});				  						galleries[195964] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Beach Pastel Paintings, Prints","link":"gallery_195964.html","maxRecords":0.0,"photoIDs":[387020.0,389656.0,389694.0,695768.0,695769.0,1541410.0,2123654.0,3239432.0,3832348.0,4205702.0,6318640.0,6321749.0,6321750.0,6321753.0,6321757.0,1278473.0],"skipIndex":0,"section_code":"gallery","featured_images":1541410.0,"id":195964,"singleSection":false});				  						galleries[350472] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Christmas and occasions Prints","link":"gallery_350472.html","maxRecords":0.0,"photoIDs":[672106.0,3080402.0,6327145.0,6327185.0,6335690.0,6335691.0,6335693.0,6519141.0,6335695.0,6321759.0,6335716.0],"skipIndex":0,"section_code":"gallery","featured_images":672106.0,"id":350472,"singleSection":false});				  						galleries[362129] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Figures, Life Drawings & Nudes in Pastels","link":"gallery_362129.html","maxRecords":0.0,"photoIDs":[9083773.0,9083785.0,9083793.0,9083799.0,9083808.0,9083836.0,9083844.0,9083851.0,9083856.0,9083862.0,9083867.0,6610009.0,6610010.0,1948841.0,1949202.0,2022118.0,6686086.0,6794149.0,7623379.0],"skipIndex":0,"section_code":"gallery","featured_images":6610009.0,"id":362129,"singleSection":false});				  						galleries[364177] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Figurative & Portrait","link":"gallery_364177.html","maxRecords":0.0,"photoIDs":[386383.0,598128.0,643470.0,818437.0,818441.0,1394902.0,1804064.0,2209407.0,6318647.0,6321748.0,6321760.0,999683.0,1060968.0,6338752.0,7294029.0,7419466.0,5363703.0,5587217.0],"skipIndex":0,"section_code":"gallery","featured_images":1394902.0,"id":364177,"singleSection":false});				  						galleries[466481] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Theatre of burlesque","link":"gallery_466481.html","maxRecords":0.0,"photoIDs":[8869267.0,8869846.0,8869848.0,8900227.0,9008186.0,2834217.0,6662702.0],"skipIndex":0,"section_code":"gallery","featured_images":9008186.0,"id":466481,"singleSection":false});				  						galleries[423018] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Artist's statement","link":"gallery_423018.html","maxRecords":0.0,"photoIDs":[7838388.0],"skipIndex":0,"section_code":"gallery","featured_images":7838388.0,"id":423018,"singleSection":false});				  						galleries[253732] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Ballet Photography and Prints","link":"gallery_253732.html","maxRecords":0.0,"photoIDs":[4304213.0,4359204.0,4489733.0,4489737.0,4489744.0,4489752.0,4489758.0,4489760.0,4489767.0,6564209.0,6564212.0,4359201.0,6564197.0,6564206.0,6564213.0,4359202.0,4359203.0,4359205.0,4359206.0,4359207.0,4359209.0,4359210.0,4359211.0,4359212.0,4359213.0,4359215.0,4359220.0,4359221.0,4359222.0],"skipIndex":0,"section_code":"gallery","featured_images":4359211.0,"id":253732,"singleSection":false});/***************************************************************************
* Create the array of image sets                                           *
***************************************************************************/
var imageSets = {};
imageSets[1] = '9079711';
imageSets[2] = '9008186,8868950,7949091,6610009,4359691,3328847,1541410,1394902,672106,7838388,4359211,3832377';
imageSets[3] = '9083867,9083862,9083856,9083851,9083844,9083836,9083808,9083799,9083793,9083785,9083773,9079711,9079710,9008186,8900236,8900227,8869848,8869846,8869840,8869267,8868950,8868947,8029916,7949091,7850722,7838388,7806950,7806936,7645393,7645386,7623379,7562819,7419466,7294029,7294024,7249604,7145897,6794149,6686086,6662702,6610012,6610011,6610010,6610009,6564213,6564212,6564209,6564206,6564197,6519141';
 /***************************************************************************
* Get a server path given an ID                                            *
***************************************************************************/
function getServerPath(server_id) {
	var val = -1;
		switch (server_id) {
		case 51:
		val = 'http://www12.clikpic.com/antell/images';
		break;
	}
		switch (server_id) {
		case 0:
		val = 'http://www.clikpic.com/antell/images';
		break;
	}
		switch (server_id) {
		case 1:
		val = 'http://www1.clikpic.com/antell/images';
		break;
	}
		switch (server_id) {
		case 2:
		val = 'http://admin.clikpic.com/antell/images';
		break;
	}
		switch (server_id) {
		case 24:
		val = 'http://tpc15/clikpic/antell/images';
		break;
	}
		switch (server_id) {
		case 4:
		val = 'http://clikchurch.clikpic.com/antell/images';
		break;
	}
		switch (server_id) {
		case 5:
		val = 'http://www2.clikpic.com/antell/images';
		break;
	}
		switch (server_id) {
		case 22:
		val = 'http://tpc5/clikpic/antell/images';
		break;
	}
		switch (server_id) {
		case 23:
		val = 'http://tpc10/clikpic/antell/images';
		break;
	}
		switch (server_id) {
		case 25:
		val = 'http://tpc16/clikpic/antell/images';
		break;
	}
		switch (server_id) {
		case 26:
		val = 'http://tpc20/clikpic/antell/images';
		break;
	}
		switch (server_id) {
		case 40:
		val = 'http://www11.clikpic.com/antell/images';
		break;
	}
		switch (server_id) {
		case 42:
		val = 'db2.clikpic.com/antell/images';
		break;
	}
		switch (server_id) {
		case 15:
		val = 'http://www3.clikpic.com/antell/images';
		break;
	}
		switch (server_id) {
		case 18:
		val = 'http://www4.clikpic.com/antell/images';
		break;
	}
		switch (server_id) {
		case 19:
		val = 'http://www5.clikpic.com/antell/images';
		break;
	}
		switch (server_id) {
		case 31:
		val = 'http://www7.clikpic.com/antell/images';
		break;
	}
		switch (server_id) {
		case 32:
		val = 'http://www8.clikpic.com/antell/images';
		break;
	}
		switch (server_id) {
		case 34:
		val = 'http://www9.clikpic.com/antell/images';
		break;
	}
		switch (server_id) {
		case 35:
		val = 'http://admin3.clikpic.com/antell/images';
		break;
	}
		switch (server_id) {
		case 37:
		val = 'http://admin4.clikpic.com/antell/images';
		break;
	}
		switch (server_id) {
		case 38:
		val = 'http://admin5.clikpic.com/antell/images';
		break;
	}
		switch (server_id) {
		case 39:
		val = 'http://www10.clikpic.com/antell/images';
		break;
	}
		switch (server_id) {
		case 53:
		val = 'http://images.clikpic.com/antell/images';
		break;
	}
		switch (server_id) {
		case 52:
		val = 'http://tpc22/clikpic/antell/images';
		break;
	}
		switch (server_id) {
		case 21:
		val = 'http://www6.clikpic.com/antell/images';
		break;
	}
		switch (server_id) {
		case 50:
		val = '[cliktext value=article.servers_id type=servers_id]/antell/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 = 'Ballet prints and Beach Prints by Robert Antell: ' + 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>Purchase now</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="antell5547@btinternet.com">';
					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="antell5547@btinternet.com">';
				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;
	}
}

			

