window.thumbnails = {};
thumbnails[7870898] = clik.newPhoto({"link":"#","caption":"ECC Logo","height":130,"id":7870898,"server_id":31,"src":"2_cm_Colour_Logo_on_black_background_thumb.jpg","galleries_id":"","width":130});
thumbnails[7687693] = clik.newPhoto({"link":"#","caption":"Millfield House","height":87,"id":7687693,"server_id":31,"src":"Millfield_Ext_Web1_thumb.jpg","galleries_id":"","width":130});
thumbnails[7817804] = clik.newPhoto({"link":"#","caption":"","height":130,"id":7817804,"server_id":31,"src":"Millfield_Map_thumb.jpg","galleries_id":"","width":130});
thumbnails[8848060] = clik.newPhoto({"link":"photo_8848060.html","caption":"Going Off Duty","height":94,"id":8848060,"server_id":31,"src":"Going_off_duty_WR_2B0BC199-24E8-5EC4-4FA297DA4D18D000_thumb.jpg","galleries_id":465332,"width":130});
thumbnails[8848061] = clik.newPhoto({"link":"photo_8848061.html","caption":"Looking Down","height":87,"id":8848061,"server_id":31,"src":"Looking_Down_WR_2B0BF05D-24E8-5EC4-4F04E52EE7E75769_thumb.jpg","galleries_id":465332,"width":130});
thumbnails[8848062] = clik.newPhoto({"link":"photo_8848062.html","caption":"Rhino","height":87,"id":8848062,"server_id":31,"src":"Rhino_WR_2B0C201D-24E8-5EC4-4FD4F342AFEBE256_thumb.jpg","galleries_id":465332,"width":130});
thumbnails[8848201] = clik.newPhoto({"link":"photo_8848201.html","caption":"St Katherine's Pier","height":87,"id":8848201,"server_id":31,"src":"KP_WR_thumb.jpg","galleries_id":465332,"width":130});
thumbnails[8888579] = clik.newPhoto({"link":"photo_8888579.html","caption":"Offerings to the Buddha","height":130,"id":8888579,"server_id":31,"src":"Offerings_to_the_Buddha_WR_F073EE10-24E8-5EC4-4FCED1B09604AC9B_thumb.jpg","galleries_id":465332,"width":87});
thumbnails[8888580] = clik.newPhoto({"link":"photo_8888580.html","caption":"Windsor Castle","height":130,"id":8888580,"server_id":31,"src":"Windsor_Castle_WR_F0745F86-24E8-5EC4-4FCEB52345F93D84_thumb.jpg","galleries_id":465332,"width":87});
thumbnails[8848385] = clik.newPhoto({"link":"photo_8848385.html","caption":"Iron Men","height":130,"id":8848385,"server_id":31,"src":"Iron_Men_WR_2D11B2E4-24E8-5EC4-4F4E8B4353BC22BA_thumb.jpg","galleries_id":422031,"width":87});
thumbnails[8848386] = clik.newPhoto({"link":"photo_8848386.html","caption":"Rafting","height":85,"id":8848386,"server_id":31,"src":"Rafting_WR_2D11E55D-24E8-5EC4-4F03CC6DD1A74EBD_thumb.jpg","galleries_id":422031,"width":130});
thumbnails[7766215] = clik.newPhoto({"link":"photo_7766215.html","caption":"Sunset Over Fjord","height":87,"id":7766215,"server_id":31,"src":"Sunset-over-FFiord-02_WR_thumb.jpg","galleries_id":419754,"width":130});
thumbnails[7766330] = clik.newPhoto({"link":"photo_7766330.html","caption":"Cathedral Detail","height":163,"id":7766330,"server_id":31,"src":"Cathedral-Detail_WR_thumb.jpg","galleries_id":419754,"width":130});
thumbnails[7766332] = clik.newPhoto({"link":"photo_7766332.html","caption":"Cosmos","height":163,"id":7766332,"server_id":31,"src":"Cosmos-White_WR_thumb.jpg","galleries_id":419754,"width":130});
thumbnails[7766335] = clik.newPhoto({"link":"photo_7766335.html","caption":"Sibelius Memorial","height":87,"id":7766335,"server_id":31,"src":"Sibelius-Monument_WR_thumb.jpg","galleries_id":419754,"width":130});
thumbnails[7766338] = clik.newPhoto({"link":"photo_7766338.html","caption":"Freesia","height":130,"id":7766338,"server_id":31,"src":"Freezia-BW_WR_thumb.jpg","galleries_id":419754,"width":130});
thumbnails[7817221] = clik.newPhoto({"link":"photo_7817221.html","caption":"Floating Silver Balls","height":87,"id":7817221,"server_id":31,"src":"Floating_Silver_Balls_WR_thumb.jpg","galleries_id":421968,"width":130});
thumbnails[7817222] = clik.newPhoto({"link":"photo_7817222.html","caption":"Fox","height":130,"id":7817222,"server_id":31,"src":"Fox_WR_thumb.jpg","galleries_id":421968,"width":130});
thumbnails[7817223] = clik.newPhoto({"link":"photo_7817223.html","caption":"Painted Lady","height":87,"id":7817223,"server_id":31,"src":"Painted_Lady_WR_thumb.jpg","galleries_id":421968,"width":130});
thumbnails[7817225] = clik.newPhoto({"link":"photo_7817225.html","caption":"Through the Trees","height":98,"id":7817225,"server_id":31,"src":"Through_the_Trees_WR_thumb.jpg","galleries_id":421968,"width":130});
thumbnails[7817226] = clik.newPhoto({"link":"photo_7817226.html","caption":"Trapped","height":87,"id":7817226,"server_id":31,"src":"Trapped_WR_thumb.jpg","galleries_id":421968,"width":130});
thumbnails[7817929] = clik.newPhoto({"link":"photo_7817929.html","caption":"Looking Up Abstract","height":98,"id":7817929,"server_id":31,"src":"Looking_Up_Abstract_WR_thumb.jpg","galleries_id":422026,"width":130});
thumbnails[7817930] = clik.newPhoto({"link":"photo_7817930.html","caption":"Asu","height":194,"id":7817930,"server_id":31,"src":"Asu_WR_thumb.jpg","galleries_id":422026,"width":130});
thumbnails[7817931] = clik.newPhoto({"link":"photo_7817931.html","caption":"Tranquility","height":87,"id":7817931,"server_id":31,"src":"Tranquility_WR_thumb.jpg","galleries_id":422026,"width":130});
thumbnails[7817932] = clik.newPhoto({"link":"photo_7817932.html","caption":"Cocoon Patterns","height":181,"id":7817932,"server_id":31,"src":"Cocoon_Patterns_WR_thumb.jpg","galleries_id":422026,"width":130});
thumbnails[7817933] = clik.newPhoto({"link":"photo_7817933.html","caption":"Puna","height":175,"id":7817933,"server_id":31,"src":"Puna_WR_thumb.jpg","galleries_id":422026,"width":130});
thumbnails[7817951] = clik.newPhoto({"link":"photo_7817951.html","caption":"Disturbing the Ground","height":81,"id":7817951,"server_id":31,"src":"Disturbing_the_Ground_WR_thumb.jpg","galleries_id":422027,"width":130});
thumbnails[7817986] = clik.newPhoto({"link":"photo_7817986.html","caption":"Honey Bee on a Mission","height":98,"id":7817986,"server_id":31,"src":"Honey_Bee_on_a_mission_WR_thumb.jpg","galleries_id":422027,"width":130});
thumbnails[7817988] = clik.newPhoto({"link":"photo_7817988.html","caption":"Liquid Lunch","height":80,"id":7817988,"server_id":31,"src":"Liquid_Lunch_WR_thumb.jpg","galleries_id":422027,"width":130});
thumbnails[7817989] = clik.newPhoto({"link":"photo_7817989.html","caption":"Marmalade Fly on Blue Fir","height":98,"id":7817989,"server_id":31,"src":"Marmalade_Fly_on_Blue_Fir_WR_thumb.jpg","galleries_id":422027,"width":130});
thumbnails[7817993] = clik.newPhoto({"link":"photo_7817993.html","caption":"On the Way Down","height":98,"id":7817993,"server_id":31,"src":"On_the_way_down_WR_thumb.jpg","galleries_id":422027,"width":130});
thumbnails[7823617] = clik.newPhoto({"link":"photo_7823617.html","caption":"Cricket","height":87,"id":7823617,"server_id":31,"src":"Cricket_WR_thumb.jpg","galleries_id":422025,"width":130});
thumbnails[7823620] = clik.newPhoto({"link":"photo_7823620.html","caption":"Dockland Reflections","height":173,"id":7823620,"server_id":31,"src":"Dockland_Reflections_WR_thumb.jpg","galleries_id":422025,"width":130});
thumbnails[7823622] = clik.newPhoto({"link":"photo_7823622.html","caption":"Derwent Water Reflections","height":66,"id":7823622,"server_id":31,"src":"Derwent_Water_Reflections_WR_thumb.jpg","galleries_id":422025,"width":130});
thumbnails[7823642] = clik.newPhoto({"link":"photo_7823642.html","caption":"Loch Nah-Achliase","height":62,"id":7823642,"server_id":31,"src":"Loch_Nah-Achlaise_Panorama_WR_thumb.jpg","galleries_id":422025,"width":130});
thumbnails[7823645] = clik.newPhoto({"link":"photo_7823645.html","caption":"Through the Grass","height":84,"id":7823645,"server_id":31,"src":"Through_the_Grass_WR_thumb.jpg","galleries_id":422025,"width":130});
thumbnails[7763987] = clik.newPhoto({"link":"photo_7763987.html","caption":"Autumn Glade","height":87,"id":7763987,"server_id":31,"src":"Autumn-glade_WR_thumb.jpg","galleries_id":419625,"width":130});
thumbnails[7764208] = clik.newPhoto({"link":"photo_7764208.html","caption":"Butterfly","height":87,"id":7764208,"server_id":31,"src":"Butterfly_WR_thumb.jpg","galleries_id":419625,"width":130});
thumbnails[7764210] = clik.newPhoto({"link":"photo_7764210.html","caption":"Cherry Blossom","height":88,"id":7764210,"server_id":31,"src":"Cherry-blossom_WR_thumb.jpg","galleries_id":419625,"width":130});
thumbnails[7764213] = clik.newPhoto({"link":"photo_7764213.html","caption":"The First Taste of Ice Cream","height":110,"id":7764213,"server_id":31,"src":"First-ice-cream_WR_thumb.jpg","galleries_id":419625,"width":130});
thumbnails[7764216] = clik.newPhoto({"link":"photo_7764216.html","caption":"I Give You Good Price!","height":195,"id":7764216,"server_id":31,"src":"I-give-you-good-price_WR_thumb.jpg","galleries_id":419625,"width":130});
thumbnails[7766151] = clik.newPhoto({"link":"photo_7766151.html","caption":"Wait","height":96,"id":7766151,"server_id":31,"src":"Wait_WR1_thumb.jpg","galleries_id":419632,"width":130});
thumbnails[7764178] = clik.newPhoto({"link":"photo_7764178.html","caption":"iPeace","height":99,"id":7764178,"server_id":31,"src":"iPeace_WR_thumb.jpg","galleries_id":419632,"width":130});
thumbnails[7766164] = clik.newPhoto({"link":"photo_7766164.html","caption":"T G I Friday","height":128,"id":7766164,"server_id":31,"src":"T-F-I-Friday_WR1_thumb.jpg","galleries_id":419632,"width":130});
thumbnails[7764186] = clik.newPhoto({"link":"photo_7764186.html","caption":"Put on Your Dancing Shoes","height":202,"id":7764186,"server_id":31,"src":"Put-on-Your-Dancing-Shoes_WR_thumb.jpg","galleries_id":419632,"width":130});
thumbnails[7764192] = clik.newPhoto({"link":"photo_7764192.html","caption":"Tranquility on Prescription","height":90,"id":7764192,"server_id":31,"src":"Tranquility-On-Prescription_WR_thumb.jpg","galleries_id":419632,"width":130});
thumbnails[7823812] = clik.newPhoto({"link":"photo_7823812.html","caption":"In a World of My own","height":98,"id":7823812,"server_id":31,"src":"In_a_World_of_my_Own_WR_thumb.jpg","galleries_id":422028,"width":130});
thumbnails[7823815] = clik.newPhoto({"link":"photo_7823815.html","caption":"The Beautiful Game","height":86,"id":7823815,"server_id":31,"src":"The_Beautiful_Game_WR_thumb.jpg","galleries_id":422028,"width":130});
thumbnails[7823853] = clik.newPhoto({"link":"photo_7823853.html","caption":"Geraldo","height":130,"id":7823853,"server_id":31,"src":"Geraldo_WR_thumb.jpg","galleries_id":422028,"width":91});
thumbnails[7823855] = clik.newPhoto({"link":"photo_7823855.html","caption":"Winter Sunrise","height":98,"id":7823855,"server_id":31,"src":"Winter_Sunrise_WR_thumb.jpg","galleries_id":422028,"width":130});
thumbnails[7823856] = clik.newPhoto({"link":"photo_7823856.html","caption":"Tate & Lite","height":98,"id":7823856,"server_id":31,"src":"Tate__Lite_WR_thumb.jpg","galleries_id":422028,"width":130});
thumbnails[7824164] = clik.newPhoto({"link":"photo_7824164.html","caption":"Reflections in an Office Window","height":89,"id":7824164,"server_id":31,"src":"Reflections_in_an_Office_Window_WR_thumb.jpg","galleries_id":422029,"width":130});
thumbnails[7824166] = clik.newPhoto({"link":"photo_7824166.html","caption":"Coffee at the Ace Cafe","height":130,"id":7824166,"server_id":31,"src":"coffee_at_th_Ace_Cafe_WR_thumb.jpg","galleries_id":422029,"width":112});
thumbnails[7824167] = clik.newPhoto({"link":"photo_7824167.html","caption":"Henlow Conservatory","height":130,"id":7824167,"server_id":31,"src":"henlow_conservatory_WR_thumb.jpg","galleries_id":422029,"width":87});
thumbnails[7824168] = clik.newPhoto({"link":"photo_7824168.html","caption":"Falling on Deaf Ears","height":130,"id":7824168,"server_id":31,"src":"falling_on_deaf_ears_WR_thumb.jpg","galleries_id":422029,"width":111});
thumbnails[7824170] = clik.newPhoto({"link":"photo_7824170.html","caption":"Simple Faith","height":99,"id":7824170,"server_id":31,"src":"simple_faith_WR_thumb.jpg","galleries_id":422029,"width":130});
thumbnails[8848223] = clik.newPhoto({"link":"photo_8848223.html","caption":"Cottage on the Moors","height":66,"id":8848223,"server_id":31,"src":"Cottage_on_the_Moors_WR_2BC313D9-24E8-5EC4-4F47E1613F66F525_thumb.jpg","galleries_id":465336,"width":130});
thumbnails[8848224] = clik.newPhoto({"link":"photo_8848224.html","caption":"Rider on the Storm","height":91,"id":8848224,"server_id":31,"src":"Rider_on_the_storm_WR_2BC357D7-24E8-5EC4-4F47655CD954F01B_thumb.jpg","galleries_id":465336,"width":130});
thumbnails[8848225] = clik.newPhoto({"link":"photo_8848225.html","caption":"The Hotdog","height":94,"id":8848225,"server_id":31,"src":"The_Hotdog_WR_2BC38C68-24E8-5EC4-4F7519F02A29796D_thumb.jpg","galleries_id":465336,"width":130});
thumbnails[8848226] = clik.newPhoto({"link":"photo_8848226.html","caption":"Water Weir","height":79,"id":8848226,"server_id":31,"src":"Water_Weir_WR_2BC3D222-24E8-5EC4-4F4A2796C4539E18_thumb.jpg","galleries_id":465336,"width":130});
thumbnails[8848291] = clik.newPhoto({"link":"photo_8848291.html","caption":"Feed the Birds","height":98,"id":8848291,"server_id":31,"src":"Feed_the_Birds_WR_2C64928E-24E8-5EC4-4F093FE4C7664828_thumb.jpg","galleries_id":465335,"width":130});
thumbnails[8848292] = clik.newPhoto({"link":"photo_8848292.html","caption":"Just the two of us","height":64,"id":8848292,"server_id":31,"src":"Just_the_two_of_us_WR_2C64DDDB-24E8-5EC4-4FBA94B0F24D447B_thumb.jpg","galleries_id":465335,"width":130});
thumbnails[8848293] = clik.newPhoto({"link":"photo_8848293.html","caption":"Near and Far WR","height":130,"id":8848293,"server_id":31,"src":"Near_and_Far_WR_2C651F46-24E8-5EC4-4FF3A2E08A9BF11C_thumb.jpg","galleries_id":465335,"width":57});
thumbnails[7824183] = clik.newPhoto({"link":"photo_7824183.html","caption":"Robin","height":110,"id":7824183,"server_id":31,"src":"Robin_WR_thumb.jpg","galleries_id":422030,"width":130});
thumbnails[7824185] = clik.newPhoto({"link":"photo_7824185.html","caption":"The Lighthouse","height":130,"id":7824185,"server_id":31,"src":"The_Lighthouse_WR_thumb.jpg","galleries_id":422030,"width":89});
thumbnails[7824187] = clik.newPhoto({"link":"photo_7824187.html","caption":"Painted Gallery","height":130,"id":7824187,"server_id":31,"src":"PaintedGallery_WR_thumb.jpg","galleries_id":422030,"width":87});
thumbnails[7824188] = clik.newPhoto({"link":"photo_7824188.html","caption":"Noah's Ark","height":130,"id":7824188,"server_id":31,"src":"Noahs_Ark_WR_thumb.jpg","galleries_id":422030,"width":87});
thumbnails[7824189] = clik.newPhoto({"link":"photo_7824189.html","caption":"Evening Light","height":87,"id":7824189,"server_id":31,"src":"Evening_Light_WR_thumb.jpg","galleries_id":422030,"width":130});
thumbnails[8848512] = clik.newPhoto({"link":"photo_8848512.html","caption":"Gone Shopping","height":130,"id":8848512,"server_id":31,"src":"Gone_Shopping_WR_2E878E24-24E8-5EC4-4F78F63235091B49_thumb.jpg","galleries_id":465360,"width":93});
thumbnails[8848511] = clik.newPhoto({"link":"photo_8848511.html","caption":"Autumn Flotsam","height":130,"id":8848511,"server_id":31,"src":"Autumn_Flotsam_WR_2E872D3F-24E8-5EC4-4F807E7D9F9DA881_thumb.jpg","galleries_id":465360,"width":87});
thumbnails[8848513] = clik.newPhoto({"link":"photo_8848513.html","caption":"Open Caps","height":87,"id":8848513,"server_id":31,"src":"Open_Caps_WR_2E880424-24E8-5EC4-4F4D9B432FD9C5DE_thumb.jpg","galleries_id":465360,"width":130});
thumbnails[8848514] = clik.newPhoto({"link":"photo_8848514.html","caption":"Tide Out","height":70,"id":8848514,"server_id":31,"src":"Tide_Out_WR_2E88478C-24E8-5EC4-4FFC508E2BEA3A8E_thumb.jpg","galleries_id":465360,"width":130});
thumbnails[7824442] = clik.newPhoto({"link":"photo_7824442.html","caption":"Oasis of Peace","height":98,"id":7824442,"server_id":31,"src":"oasis_WR_thumb.jpg","galleries_id":422032,"width":130});
thumbnails[8848305] = clik.newPhoto({"link":"photo_8848305.html","caption":"Petunia Flower","height":98,"id":8848305,"server_id":31,"src":"Petunia_Flower_WR_2C9581EA-24E8-5EC4-4F1634ADB0116173_thumb.jpg","galleries_id":422032,"width":130});
thumbnails[8848306] = clik.newPhoto({"link":"photo_8848306.html","caption":"The Thames at Night","height":99,"id":8848306,"server_id":31,"src":"The_Thames_at_Night_WR_2C95BE67-24E8-5EC4-4F75AA9707C72205_thumb.jpg","galleries_id":422032,"width":130});
thumbnails[8848304] = clik.newPhoto({"link":"photo_8848304.html","caption":"Cyclocross","height":130,"id":8848304,"server_id":31,"src":"Cyclocross_WR_2C954824-24E8-5EC4-4F8BD00BCF12ACD0_thumb.jpg","galleries_id":422032,"width":87});
thumbnails[8848365] = clik.newPhoto({"link":"photo_8848365.html","caption":"Fish and Chips","height":130,"id":8848365,"server_id":31,"src":"Fish_and_Chips_WR_2CCA482A-24E8-5EC4-4F7616741B46F646_thumb.jpg","galleries_id":465338,"width":80});
thumbnails[8848366] = clik.newPhoto({"link":"photo_8848366.html","caption":"Skyline","height":80,"id":8848366,"server_id":31,"src":"Skyline_WR_2CCA7393-24E8-5EC4-4F81FD873B1874A1_thumb.jpg","galleries_id":465338,"width":130});
thumbnails[8848368] = clik.newPhoto({"link":"photo_8848368.html","caption":"Sunny Afternoon","height":130,"id":8848368,"server_id":31,"src":"Sunny_Afternoon_WR_2CCAB79A-24E8-5EC4-4F555CE28C364BE1_thumb.jpg","galleries_id":465338,"width":87});
thumbnails[7824452] = clik.newPhoto({"link":"photo_7824452.html","caption":"Where's Everybody?","height":130,"id":7824452,"server_id":31,"src":"Wheres_Everybody_WR_thumb.jpg","galleries_id":422031,"width":87});
thumbnails[7824455] = clik.newPhoto({"link":"photo_7824455.html","caption":"Mirror Image","height":130,"id":7824455,"server_id":31,"src":"Mirror_Image_WR_thumb.jpg","galleries_id":422031,"width":87});
thumbnails[8848396] = clik.newPhoto({"link":"photo_8848396.html","caption":"Mum","height":130,"id":8848396,"server_id":31,"src":"Mum_WR_2D5596BC-24E8-5EC4-4F82920E415B2AF3_thumb.jpg","galleries_id":465337,"width":86});
thumbnails[8848397] = clik.newPhoto({"link":"photo_8848397.html","caption":"Tranqulity in Venice","height":83,"id":8848397,"server_id":31,"src":"Tranqulity_in_Venice_WR_2D55C7F7-24E8-5EC4-4FB24A00C2D8B31A_thumb.jpg","galleries_id":465337,"width":130});
thumbnails[8848398] = clik.newPhoto({"link":"photo_8848398.html","caption":"White Water Rafting","height":87,"id":8848398,"server_id":31,"src":"White_Water_Rafting_WR_2D562D52-24E8-5EC4-4FDA05E0254E9A9F_thumb.jpg","galleries_id":465337,"width":130});
thumbnails[8848395] = clik.newPhoto({"link":"photo_8848395.html","caption":"Ice Cream Vendor","height":117,"id":8848395,"server_id":31,"src":"Ice_Cream_Vendor_WR_2D555DEB-24E8-5EC4-4F06D5D61AFD4AAD_thumb.jpg","galleries_id":465337,"width":130});
thumbnails[8848407] = clik.newPhoto({"link":"photo_8848407.html","caption":"Daydreaming","height":130,"id":8848407,"server_id":31,"src":"Daydreaming_WR_2DAA658D-24E8-5EC4-4F98A49774D8E122_thumb.jpg","galleries_id":465341,"width":108});
thumbnails[8848409] = clik.newPhoto({"link":"photo_8848409.html","caption":"Hoverfly on Californian Poppy","height":91,"id":8848409,"server_id":31,"src":"Hoverfly_on_Californian_Poppy_WR_2DAAD22A-24E8-5EC4-4FC83B51161CFE83_thumb.jpg","galleries_id":465341,"width":130});
thumbnails[8848408] = clik.newPhoto({"link":"photo_8848408.html","caption":"Fungus on a Dead Stump","height":130,"id":8848408,"server_id":31,"src":"Fungus_on_a_Dead_Stump_WR_2DAAA128-24E8-5EC4-4F3D352F3FBAC566_thumb.jpg","galleries_id":465341,"width":100});
thumbnails[8848410] = clik.newPhoto({"link":"photo_8848410.html","caption":"Ramblers on Haytor","height":130,"id":8848410,"server_id":31,"src":"Ramblers_on_Haytor_WR_2DAB029B-24E8-5EC4-4FD1211817974F31_thumb.jpg","galleries_id":465341,"width":86});
thumbnails[7824704] = clik.newPhoto({"link":"photo_7824704.html","caption":"Blue & Yellow","height":87,"id":7824704,"server_id":31,"src":"Yellow__Blue_thumb.jpg","galleries_id":422033,"width":130});
thumbnails[7824705] = clik.newPhoto({"link":"photo_7824705.html","caption":"Ski Mobile","height":130,"id":7824705,"server_id":31,"src":"Ski_Mobile_WR_thumb.jpg","galleries_id":422033,"width":85});
thumbnails[7824707] = clik.newPhoto({"link":"photo_7824707.html","caption":"Taking Five","height":87,"id":7824707,"server_id":31,"src":"Taking_Five_WR_thumb.jpg","galleries_id":422033,"width":130});
thumbnails[7824720] = clik.newPhoto({"link":"photo_7824720.html","caption":"Across the River","height":98,"id":7824720,"server_id":31,"src":"Across_the_River_WR1_thumb.jpg","galleries_id":422033,"width":130});
thumbnails[7824710] = clik.newPhoto({"link":"photo_7824710.html","caption":"In the Casting Shop","height":130,"id":7824710,"server_id":31,"src":"In_the_Casting_Shop_WR_thumb.jpg","galleries_id":422033,"width":98});
thumbnails[7824489] = clik.newPhoto({"link":"photo_7824489.html","caption":"Powering Ahead","height":86,"id":7824489,"server_id":31,"src":"Powering_Ahead_WR_thumb.jpg","galleries_id":422034,"width":130});
thumbnails[7824491] = clik.newPhoto({"link":"photo_7824491.html","caption":"Arched Iceberg","height":76,"id":7824491,"server_id":31,"src":"Arched_Iceberg_WR_thumb.jpg","galleries_id":422034,"width":130});
thumbnails[7824504] = clik.newPhoto({"link":"photo_7824504.html","caption":"On the Way Down","height":86,"id":7824504,"server_id":31,"src":"On_the_Way_Down_WR1_thumb.jpg","galleries_id":422034,"width":130});
thumbnails[7824534] = clik.newPhoto({"link":"photo_7824534.html","caption":"Eventing","height":82,"id":7824534,"server_id":31,"src":"Eventing_WR_thumb.jpg","galleries_id":422034,"width":130});
thumbnails[7824558] = clik.newPhoto({"link":"photo_7824558.html","caption":"Skulls","height":130,"id":7824558,"server_id":31,"src":"Skulls_WR_thumb.jpg","galleries_id":422034,"width":74});
thumbnails[8848484] = clik.newPhoto({"link":"photo_8848484.html","caption":"Castle Stalker","height":92,"id":8848484,"server_id":31,"src":"Castle_Stalker_WR_2DFCAC94-24E8-5EC4-4FAD69A4FC22D12A_thumb.jpg","galleries_id":465339,"width":130});
thumbnails[8848485] = clik.newPhoto({"link":"photo_8848485.html","caption":"Looking Out","height":59,"id":8848485,"server_id":31,"src":"Looking_Out_WR_2DFCFC2B-24E8-5EC4-4FD473459C28CCAD_thumb.jpg","galleries_id":465339,"width":130});
thumbnails[8848486] = clik.newPhoto({"link":"photo_8848486.html","caption":"The Watch Tower ","height":77,"id":8848486,"server_id":31,"src":"The_watch_Tower_WR_2DFD4023-24E8-5EC4-4F2A5C2397934B76_thumb.jpg","galleries_id":465339,"width":130});
thumbnails[8848487] = clik.newPhoto({"link":"photo_8848487.html","caption":"Tributary to Thirlmere","height":130,"id":8848487,"server_id":31,"src":"Tributary_to_Thirlmere_WR_2DFDBF5B-24E8-5EC4-4FAD26F967A5BE62_thumb.jpg","galleries_id":465339,"width":87});
thumbnails[7824744] = clik.newPhoto({"link":"photo_7824744.html","caption":"Kite Surfer","height":91,"id":7824744,"server_id":31,"src":"Kite_Surfer_WR_thumb.jpg","galleries_id":422035,"width":130});
thumbnails[7824745] = clik.newPhoto({"link":"photo_7824745.html","caption":"Lost Soldier","height":90,"id":7824745,"server_id":31,"src":"Lost_Soldier_WR_thumb.jpg","galleries_id":422035,"width":130});
thumbnails[7824746] = clik.newPhoto({"link":"photo_7824746.html","caption":"Curly","height":87,"id":7824746,"server_id":31,"src":"Curly_WR_thumb.jpg","galleries_id":422035,"width":130});
thumbnails[7824751] = clik.newPhoto({"link":"photo_7824751.html","caption":"Pierced Tongue","height":87,"id":7824751,"server_id":31,"src":"Pierced_Tongue_WR_thumb.jpg","galleries_id":422035,"width":130});
thumbnails[7824754] = clik.newPhoto({"link":"photo_7824754.html","caption":"Self-Portrait","height":97,"id":7824754,"server_id":31,"src":"self_portrait_WR_thumb.jpg","galleries_id":422035,"width":130});
thumbnails[8848502] = clik.newPhoto({"link":"photo_8848502.html","caption":"Tourists in London","height":86,"id":8848502,"server_id":31,"src":"Tourist_in_London_WR_2E494139-24E8-5EC4-4F3420AB8D37B0E4_thumb.jpg","galleries_id":465340,"width":130});
thumbnails[8848500] = clik.newPhoto({"link":"photo_8848500.html","caption":"Eggs, Scale and Biscuits","height":86,"id":8848500,"server_id":31,"src":"Eggs_Scale_and_Biscuits_WR_2E48D46B-24E8-5EC4-4FFA485E5F37410B_thumb.jpg","galleries_id":465340,"width":130});
thumbnails[8848501] = clik.newPhoto({"link":"photo_8848501.html","caption":"Riis Park","height":86,"id":8848501,"server_id":31,"src":"Riis_Park_WR_2E491065-24E8-5EC4-4F2A67BBF81457EB_thumb.jpg","galleries_id":465340,"width":130});
thumbnails[8848499] = clik.newPhoto({"link":"photo_8848499.html","caption":"Bob","height":86,"id":8848499,"server_id":31,"src":"Bob_WR_2E48963F-24E8-5EC4-4F7B82190E2D1FA5_thumb.jpg","galleries_id":465340,"width":130});
thumbnails[8662540] = clik.newPhoto({"link":"photo_8662540.html","caption":"Original Image A","height":86,"id":8662540,"server_id":31,"src":"Portobello_Market_173_thumb.jpg","galleries_id":457384,"width":130});
thumbnails[9012944] = clik.newPhoto({"link":"photo_9012944.html","caption":"By Dave Jackson","height":120,"id":9012944,"server_id":31,"src":"Dave_A_WR_thumb.jpg","galleries_id":457384,"width":130});
thumbnails[9012955] = clik.newPhoto({"link":"photo_9012955.html","caption":"By Maggie Hughes","height":122,"id":9012955,"server_id":31,"src":"Maggie_A_WR_thumb.jpg","galleries_id":457384,"width":130});
thumbnails[8662461] = clik.newPhoto({"link":"photo_8662461.html","caption":"Original Image B","height":130,"id":8662461,"server_id":31,"src":"Cyclist_thumb.jpg","galleries_id":457384,"width":87});
thumbnails[9012972] = clik.newPhoto({"link":"photo_9012972.html","caption":"By Malcolm Rapier","height":130,"id":9012972,"server_id":31,"src":"Malcolm_B_WR_thumb.jpg","galleries_id":457384,"width":96});
thumbnails[9012974] = clik.newPhoto({"link":"photo_9012974.html","caption":"By Andy Ridley","height":130,"id":9012974,"server_id":31,"src":"Andy_B_WR_thumb.jpg","galleries_id":457384,"width":85});
thumbnails[8662611] = clik.newPhoto({"link":"photo_8662611.html","caption":"Original Image C","height":87,"id":8662611,"server_id":31,"src":"Lighthouse_thumb.jpg","galleries_id":457384,"width":130});
thumbnails[9013032] = clik.newPhoto({"link":"photo_9013032.html","caption":"By Marion Rapier","height":73,"id":9013032,"server_id":31,"src":"Marion_C_WR_thumb.jpg","galleries_id":457384,"width":130});
thumbnails[9013035] = clik.newPhoto({"link":"photo_9013035.html","caption":"By Barbara Clark","height":69,"id":9013035,"server_id":31,"src":"Barbara_C_WR_thumb.jpg","galleries_id":457384,"width":130});
thumbnails[8662612] = clik.newPhoto({"link":"photo_8662612.html","caption":"Original Image D","height":130,"id":8662612,"server_id":31,"src":"Portobello_Market_204_thumb.jpg","galleries_id":457384,"width":86});
thumbnails[9013038] = clik.newPhoto({"link":"photo_9013038.html","caption":"By Bob Ludlam","height":130,"id":9013038,"server_id":31,"src":"Bob_D_WR_thumb.jpg","galleries_id":457384,"width":86});
thumbnails[9013042] = clik.newPhoto({"link":"photo_9013042.html","caption":"By Tony Hale","height":130,"id":9013042,"server_id":31,"src":"Tony_D_WR_thumb.jpg","galleries_id":457384,"width":115});
thumbnails[8662617] = clik.newPhoto({"link":"photo_8662617.html","caption":"Original Image E","height":130,"id":8662617,"server_id":31,"src":"Walking_Man_thumb.jpg","galleries_id":457384,"width":87});
thumbnails[9013045] = clik.newPhoto({"link":"photo_9013045.html","caption":"By Chris Demetriou","height":130,"id":9013045,"server_id":31,"src":"Chris_E_WR_thumb.jpg","galleries_id":457384,"width":87});
thumbnails[9013048] = clik.newPhoto({"link":"photo_9013048.html","caption":"By Nick Clark","height":70,"id":9013048,"server_id":31,"src":"Nick_E_WR_thumb.jpg","galleries_id":457384,"width":130});

/***************************************************************************
* Create the array of Gallery objects                                      *
***************************************************************************/
var galleries = new Object();
galleries[465332] = clik.newGallery({"photoIDs":[8848060,8848061,8848062,8848201,8888579,8888580],"link":"gallery_465332.html","skipIndex":0,"section_code":"gallery","id":465332,"parentGallery":"","featured_images":"8888580,8888579,8848201,8848062,8848061,8848060","maxRecords":0,"usePopups":false,"singleSection":false,"title":"Christine Berry"});galleries[419754] = clik.newGallery({"photoIDs":[7766215,7766330,7766332,7766335,7766338],"link":"gallery_419754.html","skipIndex":0,"section_code":"gallery","id":419754,"parentGallery":"","featured_images":"7766338,7766335,7766332,7766330,7766215","maxRecords":0,"usePopups":false,"singleSection":false,"title":"Alan Bullock, LRPS"});galleries[421968] = clik.newGallery({"photoIDs":[7817221,7817222,7817223,7817225,7817226],"link":"gallery_421968.html","skipIndex":0,"section_code":"gallery","id":421968,"parentGallery":"","featured_images":"7817226,7817225,7817223,7817222,7817221","maxRecords":0,"usePopups":false,"singleSection":false,"title":"Jenny Burden"});galleries[422026] = clik.newGallery({"photoIDs":[7817929,7817930,7817931,7817932,7817933],"link":"gallery_422026.html","skipIndex":0,"section_code":"gallery","id":422026,"parentGallery":"","featured_images":"7817933,7817932,7817931,7817930,7817929","maxRecords":0,"usePopups":false,"singleSection":false,"title":"Barbara Clark"});galleries[422027] = clik.newGallery({"photoIDs":[7817951,7817986,7817988,7817989,7817993],"link":"gallery_422027.html","skipIndex":0,"section_code":"gallery","id":422027,"parentGallery":"","featured_images":"7817993,7817989,7817988,7817986,7817951","maxRecords":0,"usePopups":false,"singleSection":false,"title":"Nick Clark"});galleries[422025] = clik.newGallery({"photoIDs":[7823617,7823620,7823622,7823642,7823645],"link":"gallery_422025.html","skipIndex":0,"section_code":"gallery","id":422025,"parentGallery":"","featured_images":"7823645,7823642,7823622,7823620,7823617","maxRecords":0,"usePopups":false,"singleSection":false,"title":"Chris Demetriou"});galleries[419625] = clik.newGallery({"photoIDs":[7763987,7764208,7764210,7764213,7764216],"link":"gallery_419625.html","skipIndex":0,"section_code":"gallery","id":419625,"parentGallery":"","featured_images":"7764216,7764213,7764210,7764208,7763987","maxRecords":0,"usePopups":false,"singleSection":false,"title":"Rose Graham"});galleries[419632] = clik.newGallery({"photoIDs":[7766151,7764178,7766164,7764186,7764192],"link":"gallery_419632.html","skipIndex":0,"section_code":"gallery","id":419632,"parentGallery":"","featured_images":"7766164,7766151,7764192,7764186,7764178","maxRecords":0,"usePopups":false,"singleSection":false,"title":"David Greenshields"});galleries[422028] = clik.newGallery({"photoIDs":[7823812,7823815,7823853,7823855,7823856],"link":"gallery_422028.html","skipIndex":0,"section_code":"gallery","id":422028,"parentGallery":"","featured_images":"7823856,7823855,7823853,7823815,7823812","maxRecords":0,"usePopups":false,"singleSection":false,"title":"Tony Hale"});galleries[422029] = clik.newGallery({"photoIDs":[7824164,7824166,7824167,7824168,7824170],"link":"gallery_422029.html","skipIndex":0,"section_code":"gallery","id":422029,"parentGallery":"","featured_images":"7824170,7824168,7824167,7824166,7824164","maxRecords":0,"usePopups":false,"singleSection":false,"title":"Maggie Hughes"});galleries[465336] = clik.newGallery({"photoIDs":[8848223,8848224,8848225,8848226],"link":"gallery_465336.html","skipIndex":0,"section_code":"gallery","id":465336,"parentGallery":"","featured_images":"8848226,8848225,8848224,8848223","maxRecords":0,"usePopups":false,"singleSection":false,"title":"Craig Humphreys"});galleries[465335] = clik.newGallery({"photoIDs":[8848291,8848292,8848293],"link":"gallery_465335.html","skipIndex":0,"section_code":"gallery","id":465335,"parentGallery":"","featured_images":"8848293,8848292,8848291","maxRecords":0,"usePopups":false,"singleSection":false,"title":"Sandy Humphreys"});galleries[422030] = clik.newGallery({"photoIDs":[7824183,7824185,7824187,7824188,7824189],"link":"gallery_422030.html","skipIndex":0,"section_code":"gallery","id":422030,"parentGallery":"","featured_images":"7824189,7824188,7824187,7824185,7824183","maxRecords":0,"usePopups":false,"singleSection":false,"title":"David Jackson"});galleries[465360] = clik.newGallery({"photoIDs":[8848512,8848511,8848513,8848514],"link":"gallery_465360.html","skipIndex":0,"section_code":"gallery","id":465360,"parentGallery":"","featured_images":"8848514,8848513,8848512,8848511","maxRecords":0,"usePopups":false,"singleSection":false,"title":"Gary Jeffrey"});galleries[422032] = clik.newGallery({"photoIDs":[7824442,8848305,8848306,8848304],"link":"gallery_422032.html","skipIndex":0,"section_code":"gallery","id":422032,"parentGallery":"","featured_images":"8848306,8848305,8848304,7824442","maxRecords":0,"usePopups":false,"singleSection":false,"title":"Carla Lamb"});galleries[465338] = clik.newGallery({"photoIDs":[8848365,8848366,8848368],"link":"gallery_465338.html","skipIndex":0,"section_code":"gallery","id":465338,"parentGallery":"","featured_images":"8848368,8848366,8848365","maxRecords":0,"usePopups":false,"singleSection":false,"title":"Corinna Lamb"});galleries[422031] = clik.newGallery({"photoIDs":[8848385,8848386,7824452,7824455],"link":"gallery_422031.html","skipIndex":0,"section_code":"gallery","id":422031,"parentGallery":"","featured_images":"8848386,8848385,7824455,7824452","maxRecords":0,"usePopups":false,"singleSection":false,"title":"Ray Lamb"});galleries[465337] = clik.newGallery({"photoIDs":[8848396,8848397,8848398,8848395],"link":"gallery_465337.html","skipIndex":0,"section_code":"gallery","id":465337,"parentGallery":"","featured_images":"8848398,8848397,8848396,8848395","maxRecords":0,"usePopups":false,"singleSection":false,"title":"Bob Ludlam"});galleries[465341] = clik.newGallery({"photoIDs":[8848407,8848409,8848408,8848410],"link":"gallery_465341.html","skipIndex":0,"section_code":"gallery","id":465341,"parentGallery":"","featured_images":"8848410,8848409,8848408,8848407","maxRecords":0,"usePopups":false,"singleSection":false,"title":"John McAndrew"});galleries[422033] = clik.newGallery({"photoIDs":[7824704,7824705,7824707,7824720,7824710],"link":"gallery_422033.html","skipIndex":0,"section_code":"gallery","id":422033,"parentGallery":"","featured_images":"7824720,7824710,7824707,7824705,7824704","maxRecords":0,"usePopups":false,"singleSection":false,"title":"Malcolm Rapier, ARPS"});galleries[422034] = clik.newGallery({"photoIDs":[7824489,7824491,7824504,7824534,7824558],"link":"gallery_422034.html","skipIndex":0,"section_code":"gallery","id":422034,"parentGallery":"","featured_images":"7824558,7824534,7824504,7824491,7824489","maxRecords":0,"usePopups":false,"singleSection":false,"title":"Marion Rapier, ARPS"});galleries[465339] = clik.newGallery({"photoIDs":[8848484,8848485,8848486,8848487],"link":"gallery_465339.html","skipIndex":0,"section_code":"gallery","id":465339,"parentGallery":"","featured_images":"8848487,8848486,8848485,8848484","maxRecords":0,"usePopups":false,"singleSection":false,"title":"Elaine Rees"});galleries[422035] = clik.newGallery({"photoIDs":[7824744,7824745,7824746,7824751,7824754],"link":"gallery_422035.html","skipIndex":0,"section_code":"gallery","id":422035,"parentGallery":"","featured_images":"7824754,7824751,7824746,7824745,7824744","maxRecords":0,"usePopups":false,"singleSection":false,"title":"Andrew Ridley"});galleries[465340] = clik.newGallery({"photoIDs":[8848502,8848500,8848501,8848499],"link":"gallery_465340.html","skipIndex":0,"section_code":"gallery","id":465340,"parentGallery":"","featured_images":"8848502,8848501,8848500,8848499","maxRecords":0,"usePopups":false,"singleSection":false,"title":"Justin Thompson"});galleries[457384] = clik.newGallery({"photoIDs":[8662540,9012944,9012955,8662461,9012972,9012974,8662611,9013032,9013035,8662612,9013038,9013042,8662617,9013045,9013048],"link":"section522763.html","skipIndex":0,"section_code":"section522763","id":457384,"parentGallery":"","featured_images":"9013048,9013045,9013042,9013038,9013035,9013032,9012974,9012972,9012955,9012944","maxRecords":0,"usePopups":false,"singleSection":true,"title":"Before and After"});/***************************************************************************
* Create the array of image sets                                           *
***************************************************************************/
var imageSets = {};
imageSets[3] = '9013048,9013045,9013042,9013038,9013035,9013032,9012974,9012972,9012955,9012944,8888580,8888579,8848514,8848513,8848512,8848511,8848502,8848501,8848500,8848499,8848487,8848486,8848485,8848484,8848410,8848409,8848408,8848407,8848398,8848397,8848396,8848395,8848386,8848385,8848368,8848366,8848365,8848306,8848305,8848304,8848293,8848292,8848291,8848226,8848225,8848224,8848223,8848201,8848062,8848061';
imageSets[242425] = '7870898';
imageSets[1] = '8848061,7766215,7817221,7817929,7817951,7823617,7763987,7766151,7823812,7824164,8848224,8848291,7824183,8848304,8848365,7824452,8848396,8848407,7824704,7824489,8848484,7824744';
 /***************************************************************************
* Get a server path given an ID                                            *
***************************************************************************/
function getServerPath(server_id) {
	var val = -1;
		switch (server_id) {
		case 19:
		val = 'http://www5.clikpic.com/millfield/images';
		break;
	}
		switch (server_id) {
		case 35:
		val = 'http://admin3.clikpic.com/millfield/images';
		break;
	}
		switch (server_id) {
		case 18:
		val = 'http://www4.clikpic.com/millfield/images';
		break;
	}
		switch (server_id) {
		case 15:
		val = 'http://www3.clikpic.com/millfield/images';
		break;
	}
		switch (server_id) {
		case 34:
		val = 'http://www9.clikpic.com/millfield/images';
		break;
	}
		switch (server_id) {
		case 39:
		val = 'http://www10.clikpic.com/millfield/images';
		break;
	}
		switch (server_id) {
		case 37:
		val = 'http://admin4.clikpic.com/millfield/images';
		break;
	}
		switch (server_id) {
		case 38:
		val = 'http://admin5.clikpic.com/millfield/images';
		break;
	}
		switch (server_id) {
		case 21:
		val = 'http://www6.clikpic.com/millfield/images';
		break;
	}
		switch (server_id) {
		case 42:
		val = 'db2.clikpic.com/millfield/images';
		break;
	}
		switch (server_id) {
		case 40:
		val = 'http://www11.clikpic.com/millfield/images';
		break;
	}
		switch (server_id) {
		case 22:
		val = 'http://tpc5/clikpic/millfield/images';
		break;
	}
		switch (server_id) {
		case 23:
		val = 'http://tpc10/clikpic/millfield/images';
		break;
	}
		switch (server_id) {
		case 24:
		val = 'http://tpc15/clikpic/millfield/images';
		break;
	}
		switch (server_id) {
		case 25:
		val = 'http://tpc16/clikpic/millfield/images';
		break;
	}
		switch (server_id) {
		case 26:
		val = 'http://tpc20/clikpic/millfield/images';
		break;
	}
		switch (server_id) {
		case 2:
		val = 'http://admin.clikpic.com/millfield/images';
		break;
	}
		switch (server_id) {
		case 1:
		val = 'http://www1.clikpic.com/millfield/images';
		break;
	}
		switch (server_id) {
		case 0:
		val = 'http://www.clikpic.com/millfield/images';
		break;
	}
		switch (server_id) {
		case 5:
		val = 'http://www2.clikpic.com/millfield/images';
		break;
	}
		switch (server_id) {
		case 32:
		val = 'http://www8.clikpic.com/millfield/images';
		break;
	}
		switch (server_id) {
		case 4:
		val = 'http://clikchurch.clikpic.com/millfield/images';
		break;
	}
		switch (server_id) {
		case 31:
		val = 'http://www7.clikpic.com/millfield/images';
		break;
	}
		switch (server_id) {
		case 51:
		val = 'http://www12.clikpic.com/millfield/images';
		break;
	}
		switch (server_id) {
		case 52:
		val = 'http://tpc22/clikpic/millfield/images';
		break;
	}
		switch (server_id) {
		case 53:
		val = 'http://images.clikpic.com/millfield/images';
		break;
	}
		switch (server_id) {
		case 50:
		val = '[cliktext value=article.servers_id type=servers_id]/millfield/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 = 'Edmonton Camera Club: ' + photoCaption;
			    }
        if (op.$detail.length > 0) {
      	temp = op.nextPhoto.fnGetImageDetails();
	    op.$detail.fadeGalleryDetails(temp, op.speed, function(){
			if (typeof(backgrounds) != 'undefined' && op.nextPhoto == backgrounds[op.nextPhoto.id]) {
				toggleAddToCartConfirm(backgrounds, op.$detail);
			} else if (typeof(photos) != 'undefined' && op.nextPhoto == photos[op.nextPhoto.id]) {
				toggleAddToCartConfirm(photos, op.$detail);
			}
			$('body').trigger('clikUpdate.popup');
	    });
    }
        $(op.$detailContainer).find('.replaceable[class*=replaceable_photo-]').each(function(){
    	var field = clik.getPrefixedClass(this.className, 'replaceable_photo-');
    	if (field in op.nextPhoto) {
    		$(this).fadeGalleryDetails(op.nextPhoto[field], op.speed);
    	}
    }).end().find('.replaceable.photoPayment').fadeGalleryDetails(op.nextPhoto.fnGetPaymentInfo(), op.speed, function(){
		if (typeof(backgrounds) != 'undefined' && op.nextPhoto == backgrounds[op.nextPhoto.id]) {
			toggleAddToCartConfirm(backgrounds, op.$detailContainer);
		} else if (typeof(photos) != 'undefined' && op.nextPhoto == photos[op.nextPhoto.id]) {
			toggleAddToCartConfirm(photos, op.$detailContainer);
		}
		$('body').trigger('clikUpdate.popup');
	});
		if (op.$photo.length > 0) {
		html = $('<img/>',{
			'class': 'mainphoto photo',
			src: photoSrc,
			id: 'mainPic',
			name: 'mainPic',
			width: op.nextPhoto.width,
			height: op.nextPhoto.height,
			alt: photoCaption,
			css: op.css || {}
		});
		if (op.href) {
			if (op.href.match(/<a/)) {
				html = $(op.href).append(html);
			} else {
				html = $('<a/>', {
					href: op.href,
					title: photoCaption
				}).append(html);
			}
		} else {
			html = $('<a/>', {
				title: photoCaption
			}).append(html);
		}
		if (op.speed == 0) {			op.$photo.html(html);			if (op.onBefore) {			  	op.onBefore.apply(op.$photo);			}			if (op.onAfter) {			  	op.onAfter.apply(op.$photo);			}		} else {			op.$photo.stop(true,true).fadeReplaceWith(html,op.speed,'',function(){  				if (op.onAfter) {				  	op.onAfter.apply(this);				}				clik.doColumnResize(false, $(this).add(op.$detail).add(op.$title));			}, op.onBefore);
		}	}
    if (op.field) {
		op.field.value = photoId;
	} else {
		op.$photo.data('image_id', photoId);
    }
        if (!op.speed) {
      	clik.doColumnResize(false, op.$photo.add(op.$detail).add(op.$title));
    }
        
    return html;
	}

/***************************************************************************
* Toggle add to cart confirmation element and set up the click event for   *
* the 'Add to cart' button.                                                *
***************************************************************************/
function toggleAddToCartConfirm(array, root){
	if (typeof(array) !== 'object' || array === null) {
	  	array = photos;
	}
	if (!$(root).length) {		root = $('body');	}	if($('#paymentConfirm', root).length > 0){
		$('#paymentConfirm', root).hide();
		$('#paymentAddButton', root)
		.unbind()
		.click(function(){
						form = $('#paymentForm', root)[0];
			option_id = 0;
			if(form.item_option.value){
				option_id = form.item_option.value;
			}
			if(addItemToBasket(form.item_number.value,array,form.site.value,parseInt(form.quantity.value, 10),option_id)){
				if($.browser.msie){$('#paymentConfirm', root).text('Item added to cart').show();}
				else{
					$('#paymentConfirm', root).text('Item added to cart').fadeIn();
					dspOrderDetails(form.site.value);
				}
			}
			else{
				$('#paymentConfirm', root).text('Item not added - check cookies are enabled in your browser.').fadeIn();
			}
		});
	}
}

/***************************************************************************
* Get payment info for image - add as 'method' to photo object             *
***************************************************************************/
clik.photo.fnGetImageDetails = function(){
	var temp = '';
	if (this.description != '') {
		temp +=  '<div id="imageDescription">' + this.description + '</div>';
	}
		if (this.photo_ref != '') {
		temp += '<div class="imageinfo" id="imageRef"><strong>Ref: </strong>' + this.photo_ref + '</div>';
	}
		if (this.takendate != '') {
		
		temp += '<div class="imageinfo" id="imageDate"><strong>Date: </strong>' + this.takendate + '</div>';
	}
	
	if (this.location != '') {
		
		temp += '<div class="imageinfo" id="imageLocation"><strong>Location: </strong>' +  this.location + '</div>';
	}
	
	if (this.photographer != '') {
		
		temp += '<div class="imageinfo" id="imagePhotographer"><strong>Photographer: </strong>' + this.photographer + '</div>';
	}
			
				if (temp != '') {
		temp += '<div class="spacer"></div>';
	}
	return temp;
};

/***************************************************************************
* Get payment info for image - add as 'method' to photo object             *
***************************************************************************/
clik.photo.fnGetPaymentInfo = function(){
	var temp = '';
	if (this.item_price !== '') {
				temp += '<p>Order this print:</p>';
				temp += '<div class="imageinfo" id="imagePrice"><strong>' + this.purchase_instruction + '</strong> ' + (this.item_price).toFixed(2) + '</div>';
		var item_name  = this.purchase_instruction;
		var amount = (this.item_price).toFixed(2);
		var item_option  = 0;
	}
		else {
		
	}
	if (this.item_price !== '') {
			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;
	}
}

		

