window.thumbnails = {};
															thumbnails[8289811] = clik.newPhoto({"id":8289811,"src":"Baby_Giraffe_web_thumb.jpg","galleries_id":70883,"server_id":19,"link":"photo_8289811.html","width":130,"caption":"Baby Giraffe","height":100});
															thumbnails[8289900] = clik.newPhoto({"id":8289900,"src":"Rhino_BW_web_thumb.jpg","galleries_id":70883,"server_id":19,"link":"photo_8289900.html","width":130,"caption":"White Rhino","height":105});
															thumbnails[8289904] = clik.newPhoto({"id":8289904,"src":"Baby_looking_at_mum_web_thumb.jpg","galleries_id":70883,"server_id":19,"link":"photo_8289904.html","width":130,"caption":"Rhesus Monkeys","height":90});
															thumbnails[8289911] = clik.newPhoto({"id":8289911,"src":"Gofer_web_thumb.jpg","galleries_id":70883,"server_id":19,"link":"photo_8289911.html","width":130,"caption":"Gopher","height":196});
															thumbnails[5291444] = clik.newPhoto({"id":5291444,"src":"Robin_web_thumb.jpg","galleries_id":70883,"server_id":18,"link":"photo_5291444.html","width":130,"caption":"Robin","height":146});
															thumbnails[5291454] = clik.newPhoto({"id":5291454,"src":"Swan_Head__Neck_web_thumb.jpg","galleries_id":70883,"server_id":18,"link":"photo_5291454.html","width":130,"caption":"Swan","height":138});
															thumbnails[5127384] = clik.newPhoto({"id":5127384,"src":"1940s_theme_web_thumb.jpg","galleries_id":70876,"server_id":18,"link":"photo_5127384.html","width":130,"caption":"Locomotive, Woody Bay North Devon","height":98});
															thumbnails[5127397] = clik.newPhoto({"id":5127397,"src":"King_of_the_jungle_bw_web_thumb.jpg","galleries_id":70883,"server_id":18,"link":"photo_5127397.html","width":130,"caption":"King of The Jungle","height":173});
															thumbnails[5127483] = clik.newPhoto({"id":5127483,"src":"Aphrodite_Sunset_montage_web_thumb.jpg","galleries_id":70879,"server_id":18,"link":"photo_5127483.html","width":130,"caption":"Aphrodite's Rock, Cyprus","height":181});
															thumbnails[5127488] = clik.newPhoto({"id":5127488,"src":"Lofu_roof_tops_web_thumb.jpg","galleries_id":70876,"server_id":18,"link":"photo_5127488.html","width":130,"caption":"Lofu Cyprus","height":182});
															thumbnails[5127493] = clik.newPhoto({"id":5127493,"src":"Ship_wreck_at_Akrotiri_Peninsula_web_thumb.jpg","galleries_id":70879,"server_id":18,"link":"photo_5127493.html","width":130,"caption":"Wreck of Akrotiri Peninsula","height":173});
															thumbnails[3031578] = clik.newPhoto({"id":3031578,"src":"Bryn Weston S Mare web_thumb.jpg","galleries_id":70874,"server_id":18,"link":"photo_3031578.html","width":130,"caption":"Thoughtful Bryn","height":120});
															thumbnails[3031343] = clik.newPhoto({"id":3031343,"src":"Leaves web shot_thumb.jpg","galleries_id":70880,"server_id":18,"link":"photo_3031343.html","width":130,"caption":"Autumn Westonburt Aboretum","height":98});
															thumbnails[3031425] = clik.newPhoto({"id":3031425,"src":"Tree at Westonburt_thumb.jpg","galleries_id":70880,"server_id":18,"link":"photo_3031425.html","width":130,"caption":"Green Tree","height":109});
															thumbnails[3031561] = clik.newPhoto({"id":3031561,"src":"Golden trees_thumb.jpg","galleries_id":70880,"server_id":18,"link":"photo_3031561.html","width":130,"caption":"Golden Trees","height":173});
															thumbnails[2945111] = clik.newPhoto({"id":2945111,"src":"Bethan Cypress gardens B+W Web_thumb.jpg","galleries_id":70874,"server_id":18,"link":"photo_2945111.html","width":130,"caption":"Bethan","height":161});
															thumbnails[2945077] = clik.newPhoto({"id":2945077,"src":"Bryn B+W Web_thumb.jpg","galleries_id":70874,"server_id":18,"link":"photo_2945077.html","width":130,"caption":"Bryn","height":91});
															thumbnails[2945098] = clik.newPhoto({"id":2945098,"src":"Owain at water park B + W web_thumb.jpg","galleries_id":70874,"server_id":18,"link":"photo_2945098.html","width":130,"caption":"Owain","height":192});
															thumbnails[2868794] = clik.newPhoto({"id":2868794,"src":"USA Niagra panorama web_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_2868794.html","width":129,"caption":"Niagara","height":52});
															thumbnails[2126487] = clik.newPhoto({"id":2126487,"src":"web Charing X walk bridge_thumb.jpg","galleries_id":70879,"server_id":18,"link":"photo_2126487.html","width":130,"caption":"Charing Cross Bridge","height":175});
															thumbnails[2126491] = clik.newPhoto({"id":2126491,"src":"web London eye & Big Ben11_thumb.jpg","galleries_id":70876,"server_id":18,"link":"photo_2126491.html","width":130,"caption":"Thames from Charing Cross Bridge","height":68});
															thumbnails[2126495] = clik.newPhoto({"id":2126495,"src":"web Charing X bridge_thumb.jpg","galleries_id":70879,"server_id":18,"link":"photo_2126495.html","width":130,"caption":"Charing Cross Station","height":145});
															thumbnails[2104756] = clik.newPhoto({"id":2104756,"src":"(web) Boat in St Miguel Bay_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_2104756.html","width":130,"caption":"Fishing off Tenerife","height":84});
															thumbnails[2104762] = clik.newPhoto({"id":2104762,"src":"Web Mt Teide_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_2104762.html","width":130,"caption":"Mt Teide, Tenerife","height":173});
															thumbnails[2104846] = clik.newPhoto({"id":2104846,"src":"(Web) St Miguel Marina_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_2104846.html","width":130,"caption":"St Miguel Marina","height":176});
															thumbnails[1811075] = clik.newPhoto({"id":1811075,"src":"Click pic Caerphilly Castle3_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_1811075.html","width":130,"caption":"Caerphilly Castle","height":69});
															thumbnails[1811093] = clik.newPhoto({"id":1811093,"src":"Pencoed Castle B+W Edited_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_1811093.html","width":130,"caption":"Pencoed Castle","height":91});
															thumbnails[1761505] = clik.newPhoto({"id":1761505,"src":"clikpic, Symphony glade ski area_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_1761505.html","width":130,"caption":"Symphony ski area Whistler Mountain","height":98});
															thumbnails[1761545] = clik.newPhoto({"id":1761545,"src":"Clikpic Black Tusk Mountain_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_1761545.html","width":130,"caption":"View from Whistler Peak","height":67});
															thumbnails[1761628] = clik.newPhoto({"id":1761628,"src":"Clikpic, Blackcomb Mountain from Symphony ski area1_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_1761628.html","width":130,"caption":"Blackcomb Ski area from Whistler Mountain","height":173});
															thumbnails[1761682] = clik.newPhoto({"id":1761682,"src":"Clikpic, Snow & Ice night 30 Dec 07_thumb.jpg","galleries_id":70876,"server_id":18,"link":"photo_1761682.html","width":130,"caption":"Snow & Ice show Whistler","height":89});
															thumbnails[1761700] = clik.newPhoto({"id":1761700,"src":"Clikpic, Whistler Brewhouse_thumb.jpg","galleries_id":70876,"server_id":18,"link":"photo_1761700.html","width":130,"caption":"Brewhouse Whistler Village","height":95});
															thumbnails[1762026] = clik.newPhoto({"id":1762026,"src":"Clikpic, Village Walk bridge1_thumb.jpg","galleries_id":70876,"server_id":18,"link":"photo_1762026.html","width":130,"caption":"Village Walk, Whistler Village","height":128});
															thumbnails[1761580] = clik.newPhoto({"id":1761580,"src":"Blackcomb Clickpic, Mountain from Whistler Mountain in sepia copy_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_1761580.html","width":130,"caption":"Blackcomb Mountain from Whistler Roundhouse","height":98});
															thumbnails[1761488] = clik.newPhoto({"id":1761488,"src":"Clikpic, River from covered bridge_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_1761488.html","width":130,"caption":"Whistler river walk","height":173});
															thumbnails[1761558] = clik.newPhoto({"id":1761558,"src":"Clikpic, Bridge between Upper & Lower Village_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_1761558.html","width":130,"caption":"Bridge between Upper & Lower villages","height":98});
															thumbnails[1761640] = clik.newPhoto({"id":1761640,"src":"Clickpic, Wintery river walk_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_1761640.html","width":130,"caption":"Winter walk","height":173});
															thumbnails[1762036] = clik.newPhoto({"id":1762036,"src":"Clikpic, SSC Nov 4th 07_thumb.jpg","galleries_id":70879,"server_id":18,"link":"photo_1762036.html","width":130,"caption":"Sunset over Second severn Crossing","height":84});
															thumbnails[1026439] = clik.newPhoto({"id":1026439,"src":"SSC May 29 2007_thumb.jpg","galleries_id":70879,"server_id":18,"link":"photo_1026439.html","width":130,"caption":"Second Severn Crossing","height":172});
															thumbnails[1026546] = clik.newPhoto({"id":1026546,"src":"Under SSC_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_1026546.html","width":130,"caption":"Under the SSC","height":185});
															thumbnails[984051] = clik.newPhoto({"id":984051,"src":"Transporter Bridge Newport_thumb.jpg","galleries_id":70879,"server_id":18,"link":"photo_984051.html","width":130,"caption":"Transporter Bridge","height":173});
															thumbnails[957679] = clik.newPhoto({"id":957679,"src":"Peacock_thumb.jpg","galleries_id":70883,"server_id":18,"link":"photo_957679.html","width":130,"caption":"Peacock","height":176});
															thumbnails[953501] = clik.newPhoto({"id":953501,"src":"Tintern Abbey_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_953501.html","width":130,"caption":"Tintern Abbey","height":98});
															thumbnails[944826] = clik.newPhoto({"id":944826,"src":"Bryn & SSC sunset_thumb.jpg","galleries_id":70879,"server_id":18,"link":"photo_944826.html","width":130,"caption":"Bryn at Second Severn Crossing","height":167});
															thumbnails[931750] = clik.newPhoto({"id":931750,"src":"Tower Lake_thumb.jpg","galleries_id":70879,"server_id":18,"link":"photo_931750.html","width":130,"caption":"Tower Lake, Haines City Florida","height":173});
															thumbnails[931758] = clik.newPhoto({"id":931758,"src":"st pauls_thumb.jpg","galleries_id":70876,"server_id":18,"link":"photo_931758.html","width":130,"caption":"St Pauls, London","height":98});
															thumbnails[931863] = clik.newPhoto({"id":931863,"src":"Rainbow over the City_thumb.jpg","galleries_id":70876,"server_id":18,"link":"photo_931863.html","width":130,"caption":"Rainbow over the City of London","height":98});
															thumbnails[1026554] = clik.newPhoto({"id":1026554,"src":"Paris & Aladdin1_thumb.jpg","galleries_id":70876,"server_id":18,"link":"photo_1026554.html","width":130,"caption":"Vegas strip","height":99});
															thumbnails[931767] = clik.newPhoto({"id":931767,"src":"Tower Bridge_thumb.jpg","galleries_id":70876,"server_id":18,"link":"photo_931767.html","width":130,"caption":"Tower Bridge, London","height":98});
															thumbnails[931771] = clik.newPhoto({"id":931771,"src":"Englewood Beach, Gulf Coast_thumb.jpg","galleries_id":70879,"server_id":18,"link":"photo_931771.html","width":130,"caption":"Englewood Beach","height":98});
															thumbnails[931773] = clik.newPhoto({"id":931773,"src":"Thames_thumb.JPG","galleries_id":70878,"server_id":18,"link":"photo_931773.html","width":130,"caption":"Thames at Windsor","height":90});
															thumbnails[931776] = clik.newPhoto({"id":931776,"src":"British Museum_thumb.jpg","galleries_id":70876,"server_id":18,"link":"photo_931776.html","width":130,"caption":"Main Hall at British Museum","height":173});
															thumbnails[931780] = clik.newPhoto({"id":931780,"src":"We do have snow!_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_931780.html","width":130,"caption":"Llandevaud woods","height":98});
															thumbnails[931786] = clik.newPhoto({"id":931786,"src":"Daffodils_thumb.jpg","galleries_id":70880,"server_id":18,"link":"photo_931786.html","width":130,"caption":"Daffodils","height":174});
															thumbnails[931795] = clik.newPhoto({"id":931795,"src":"Fly on the Daffs_thumb.jpg","galleries_id":70880,"server_id":18,"link":"photo_931795.html","width":130,"caption":"Fly on the Daffodils","height":98});
															thumbnails[931816] = clik.newPhoto({"id":931816,"src":"Both on dads chair1_thumb.jpg","galleries_id":70883,"server_id":18,"link":"photo_931816.html","width":130,"caption":"Caesar & Troy on \"their chair\"","height":83});
															thumbnails[931820] = clik.newPhoto({"id":931820,"src":"caesar_thumb.JPG","galleries_id":70883,"server_id":18,"link":"photo_931820.html","width":130,"caption":"Caesar the Labrador","height":98});
															thumbnails[931862] = clik.newPhoto({"id":931862,"src":"Manakin on Thames_thumb.jpg","galleries_id":70874,"server_id":18,"link":"photo_931862.html","width":130,"caption":"Manakin on the Thames Embankment","height":173});
															thumbnails[931879] = clik.newPhoto({"id":931879,"src":"Horse Chestnut_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_931879.html","width":130,"caption":"Weather breaking behind Horse Chestnut ","height":98});
															thumbnails[931893] = clik.newPhoto({"id":931893,"src":"Horseguards Parade in March_thumb.jpg","galleries_id":70876,"server_id":18,"link":"photo_931893.html","width":130,"caption":"Horseguards parade in March","height":173});
															thumbnails[932077] = clik.newPhoto({"id":932077,"src":"Oz_thumb.jpg","galleries_id":70883,"server_id":18,"link":"photo_932077.html","width":130,"caption":"Oz","height":173});
															thumbnails[932078] = clik.newPhoto({"id":932078,"src":"Sunset over the Gulf1_thumb.jpg","galleries_id":70879,"server_id":18,"link":"photo_932078.html","width":130,"caption":"Sunset over the Gulf of Mexico","height":98});
															thumbnails[944828] = clik.newPhoto({"id":944828,"src":"SSC sunset_thumb.jpg","galleries_id":70879,"server_id":18,"link":"photo_944828.html","width":130,"caption":"SSC at sunset","height":174});
															thumbnails[1811276] = clik.newPhoto({"id":1811276,"src":"Heritage Park Pontypridd_thumb.jpg","galleries_id":70876,"server_id":18,"link":"photo_1811276.html","width":130,"caption":"Heritage Park","height":176});
															thumbnails[1811279] = clik.newPhoto({"id":1811279,"src":"Usk in flood copy_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_1811279.html","width":130,"caption":"River Usk in flood","height":237});
															thumbnails[5268423] = clik.newPhoto({"id":5268423,"src":"Blackcombe_river_in_sepia_web_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_5268423.html","width":130,"caption":"Blackcombe River","height":173});
															thumbnails[5268437] = clik.newPhoto({"id":5268437,"src":"Alpine_Treeline_web_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_5268437.html","width":130,"caption":"Alpine Tree Line","height":84});
															thumbnails[5268442] = clik.newPhoto({"id":5268442,"src":"Blackcombe_Mountain_Whistler_web_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_5268442.html","width":130,"caption":"Blackcombe Mountain","height":71});
															thumbnails[5268443] = clik.newPhoto({"id":5268443,"src":"Bryn_Tower_Lakes_Web_thumb.jpg","galleries_id":70874,"server_id":18,"link":"photo_5268443.html","width":130,"caption":"Bryn Tower Lakes","height":161});
															thumbnails[5268447] = clik.newPhoto({"id":5268447,"src":"Cardiff_Bay_Dodged__Burned_web_thumb.jpg","galleries_id":70876,"server_id":18,"link":"photo_5268447.html","width":130,"caption":"Cardiff Bay","height":93});
															thumbnails[5268452] = clik.newPhoto({"id":5268452,"src":"Entrance_to_castle_BW_web_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_5268452.html","width":130,"caption":"Pencoed Castle","height":98});
															thumbnails[5268458] = clik.newPhoto({"id":5268458,"src":"Entrance_to_Paxtons_tower_B__W_web_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_5268458.html","width":130,"caption":"View Through Paxton's Tower","height":184});
															thumbnails[5268459] = clik.newPhoto({"id":5268459,"src":"Kew_Orchid_Web_thumb.jpg","galleries_id":70880,"server_id":18,"link":"photo_5268459.html","width":130,"caption":"Kew Orchid","height":151});
															thumbnails[5268460] = clik.newPhoto({"id":5268460,"src":"King_of_the_Beasts_web_thumb.jpg","galleries_id":70883,"server_id":18,"link":"photo_5268460.html","width":130,"caption":"Lion","height":168});
															thumbnails[5268462] = clik.newPhoto({"id":5268462,"src":"Miner__Ship_HDR_Dodged__Burned_web_thumb.jpg","galleries_id":70876,"server_id":18,"link":"photo_5268462.html","width":130,"caption":"Cardiff Miner","height":194});
															thumbnails[5268464] = clik.newPhoto({"id":5268464,"src":"Orchid_Kew_Gardens_web_thumb.jpg","galleries_id":70880,"server_id":18,"link":"photo_5268464.html","width":130,"caption":"Orchid","height":159});
															thumbnails[5268466] = clik.newPhoto({"id":5268466,"src":"owl_close_up_web_thumb.jpg","galleries_id":70883,"server_id":18,"link":"photo_5268466.html","width":130,"caption":"","height":98});
															thumbnails[5268467] = clik.newPhoto({"id":5268467,"src":"Padstow_Harbour_web_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_5268467.html","width":130,"caption":"Padstow Harbour","height":98});
															thumbnails[5268469] = clik.newPhoto({"id":5268469,"src":"Paxtons_Tower_Dodged__Burned_web_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_5268469.html","width":130,"caption":"Paxton's Tower","height":141});
															thumbnails[5268470] = clik.newPhoto({"id":5268470,"src":"Rhosilli_Bay_boat_house_Dodged__Burned_web_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_5268470.html","width":130,"caption":"Rhosilli Bay","height":173});
															thumbnails[5268473] = clik.newPhoto({"id":5268473,"src":"Storm_approaching_cliffs_web_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_5268473.html","width":130,"caption":"Padstow Cornwall","height":174});
															thumbnails[5268475] = clik.newPhoto({"id":5268475,"src":"Storm_on_the_way_web_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_5268475.html","width":130,"caption":"Late Summer Storm","height":98});
															thumbnails[5268506] = clik.newPhoto({"id":5268506,"src":"Wild_Flowers_Rhosilli_Bay_web_thumb.jpg","galleries_id":70880,"server_id":18,"link":"photo_5268506.html","width":130,"caption":"Wild Flowers","height":195});
															thumbnails[5268508] = clik.newPhoto({"id":5268508,"src":"Entrance_to_castle_web_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_5268508.html","width":130,"caption":"Pencoed Castle","height":99});
															thumbnails[5268509] = clik.newPhoto({"id":5268509,"src":"Cardiff_Bay_Dodged__Burned_web1_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_5268509.html","width":130,"caption":"Cardiff Bay Barrage","height":93});
															thumbnails[5268549] = clik.newPhoto({"id":5268549,"src":"Lilly_web_thumb.jpg","galleries_id":70880,"server_id":18,"link":"photo_5268549.html","width":130,"caption":"Lilly","height":173});
															thumbnails[5291452] = clik.newPhoto({"id":5291452,"src":"Goodrich_HD_web_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_5291452.html","width":130,"caption":"Goodrich Castle","height":173});
															thumbnails[5291466] = clik.newPhoto({"id":5291466,"src":"Caesar_BW_web_thumb.jpg","galleries_id":70883,"server_id":18,"link":"photo_5291466.html","width":130,"caption":"Caesar ","height":133});
															thumbnails[5430438] = clik.newPhoto({"id":5430438,"src":"Entrance_to_castle_web_moon_effect_web_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_5430438.html","width":130,"caption":"Pencoed Castle moonlight","height":137});
															thumbnails[5430469] = clik.newPhoto({"id":5430469,"src":"Bird_Breath1_for_web_thumb.jpg","galleries_id":70883,"server_id":18,"link":"photo_5430469.html","width":130,"caption":"Bird's Breath","height":154});
															thumbnails[5430491] = clik.newPhoto({"id":5430491,"src":"Storm_over_Manhatten_web_page_thumb.jpg","galleries_id":70876,"server_id":18,"link":"photo_5430491.html","width":130,"caption":"Manhattan Storm","height":103});
															thumbnails[5454901] = clik.newPhoto({"id":5454901,"src":"Pencoed_Castle_bleak_winter_afternoon_web1_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_5454901.html","width":130,"caption":"Pencoed Castle, Winters view","height":93});
															thumbnails[5667439] = clik.newPhoto({"id":5667439,"src":"Upper_Neuadd_Reservoir_Panorama_web_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_5667439.html","width":130,"caption":"Neuadd Reservoir Brecon Beacons","height":36});
															thumbnails[5667441] = clik.newPhoto({"id":5667441,"src":"Pen_Y_Fan_Web_thumb.jpg","galleries_id":70878,"server_id":18,"link":"photo_5667441.html","width":130,"caption":"Pen-y-Fan Brecon Beacons","height":195});
															thumbnails[7513251] = clik.newPhoto({"id":7513251,"src":"Burj__lamp_clicpik_thumb.jpg","galleries_id":70876,"server_id":18,"link":"photo_7513251.html","width":130,"caption":"Burg Khalifa","height":195});
															thumbnails[7513254] = clik.newPhoto({"id":7513254,"src":"Burj_Khalifa_Burj_Arab__Jumeira_Beach_Hotel_clicpik_thumb.jpg","galleries_id":70876,"server_id":18,"link":"photo_7513254.html","width":130,"caption":"Burg Khalifa Burg Al Arab & Jumeirah Beach Hotel","height":87});
															thumbnails[7513255] = clik.newPhoto({"id":7513255,"src":"Burj_Khalifa_Close_Up_BW_clicpik_thumb.jpg","galleries_id":70876,"server_id":18,"link":"photo_7513255.html","width":130,"caption":"Burg Khalifa up close","height":189});
															thumbnails[7513256] = clik.newPhoto({"id":7513256,"src":"Dubai_night_skyline_web_clicpik_thumb.jpg","galleries_id":70876,"server_id":18,"link":"photo_7513256.html","width":130,"caption":"Dubai Sunset","height":82});
															thumbnails[7513258] = clik.newPhoto({"id":7513258,"src":"Desert_Cat_Al_Ain_clicpik_thumb.jpg","galleries_id":70883,"server_id":18,"link":"photo_7513258.html","width":130,"caption":"Desert Cat","height":161});
															thumbnails[7513261] = clik.newPhoto({"id":7513261,"src":"camel_faces2_clicpik_thumb.jpg","galleries_id":70883,"server_id":18,"link":"photo_7513261.html","width":130,"caption":"The face says it all","height":118});
															thumbnails[7513262] = clik.newPhoto({"id":7513262,"src":"Camel_silouette_deviant_art_clicpik1_thumb.jpg","galleries_id":70883,"server_id":18,"link":"photo_7513262.html","width":130,"caption":"Sunset Camel","height":151});
															thumbnails[7513264] = clik.newPhoto({"id":7513264,"src":"camel_racers_clicpik1_thumb.jpg","galleries_id":70883,"server_id":38,"link":"photo_7513264.html","width":130,"caption":"Camel racers","height":55});
															thumbnails[8289597] = clik.newPhoto({"id":8289597,"src":"wing_view_BW_web_thumb.jpg","galleries_id":70876,"server_id":19,"link":"photo_8289597.html","width":130,"caption":"Under Wing","height":88});
															thumbnails[8289599] = clik.newPhoto({"id":8289599,"src":"loading_BW_web_thumb.jpg","galleries_id":70876,"server_id":19,"link":"photo_8289599.html","width":130,"caption":"Offloading B747","height":89});

/***************************************************************************
* Create the array of Gallery objects                                      *
***************************************************************************/
var galleries = new Object();
				  						galleries[70883] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Birds & Animals","link":"gallery_70883.html","maxRecords":0.0,"photoIDs":[8289811.0,8289900.0,8289904.0,8289911.0,5291444.0,5291454.0,5127397.0,957679.0,931816.0,931820.0,932077.0,5268460.0,5268466.0,5291466.0,5430469.0,7513258.0,7513261.0,7513262.0,7513264.0],"skipIndex":0,"section_code":"gallery","featured_images":"8289911,8289904,8289900,8289811,7513264,7513262,7513261,7513258,5430469,5291466","id":70883,"singleSection":false});				  						galleries[70880] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Flowers, Plants & Trees","link":"gallery_70880.html","maxRecords":0.0,"photoIDs":[3031343.0,3031425.0,3031561.0,931786.0,931795.0,5268459.0,5268464.0,5268506.0,5268549.0],"skipIndex":0,"section_code":"gallery","featured_images":"5268549,5268506,5268464,5268459,3031561,3031425,3031343,931795,931786","id":70880,"singleSection":false});				  						galleries[70876] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"In the city","link":"gallery_70876.html","maxRecords":0.0,"photoIDs":[5127384.0,5127488.0,2126491.0,1761682.0,1761700.0,1762026.0,931758.0,931863.0,1026554.0,931767.0,931776.0,931893.0,1811276.0,5268447.0,5268462.0,5430491.0,7513251.0,7513254.0,7513255.0,7513256.0,8289597.0,8289599.0],"skipIndex":0,"section_code":"gallery","featured_images":"8289599,8289597,7513256,7513255,7513254,7513251,5430491,5268462,5268447,5127488","id":70876,"singleSection":false});				  						galleries[70878] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Landscapes","link":"gallery_70878.html","maxRecords":0.0,"photoIDs":[2868794.0,2104756.0,2104762.0,2104846.0,1811075.0,1811093.0,1761505.0,1761545.0,1761628.0,1761580.0,1761488.0,1761558.0,1761640.0,1026546.0,953501.0,931773.0,931780.0,931879.0,1811279.0,5268423.0,5268437.0,5268442.0,5268452.0,5268458.0,5268467.0,5268469.0,5268470.0,5268473.0,5268475.0,5268508.0,5268509.0,5291452.0,5430438.0,5454901.0,5667439.0,5667441.0],"skipIndex":0,"section_code":"gallery","featured_images":"5667441,5667439,5454901,5430438,5291452,5268509,5268508,5268475,5268473,5268470","id":70878,"singleSection":false});				  						galleries[70874] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"People","link":"gallery_70874.html","maxRecords":0.0,"photoIDs":[3031578.0,2945111.0,2945077.0,2945098.0,931862.0,5268443.0],"skipIndex":0,"section_code":"gallery","featured_images":"5268443,3031578,2945111,2945098,2945077,931862","id":70874,"singleSection":false});				  						galleries[70879] = clik.newGallery({"parentGallery":"","usePopups":false,"title":"Sunsets","link":"gallery_70879.html","maxRecords":0.0,"photoIDs":[5127483.0,5127493.0,2126487.0,2126495.0,1762036.0,1026439.0,984051.0,944826.0,931750.0,931771.0,932078.0,944828.0],"skipIndex":0,"section_code":"gallery","featured_images":"5127493,5127483,2126495,2126487,1762036,1026439,984051,944828,944826,932078","id":70879,"singleSection":false});/***************************************************************************
* Create the array of image sets                                           *
***************************************************************************/
var imageSets = {};
imageSets[1] = '1761545';
imageSets[3] = '8289911,8289904,8289900,8289811,8289599,8289597,7513264,7513262,7513261,7513258,7513256,7513255,7513254,7513251,5667441,5667439,5454901,5430491,5430469,5430438,5291466,5291454,5291452,5291444,5268549,5268509,5268508,5268506,5268475,5268473,5268470,5268469,5268467,5268466,5268464,5268462,5268460,5268459,5268458,5268452,5268447,5268443,5268442,5268437,5268423,5127493,5127488,5127483,5127397,5127384';
 /***************************************************************************
* Get a server path given an ID                                            *
***************************************************************************/
function getServerPath(server_id) {
	var val = -1;
		switch (server_id) {
		case 21:
		val = 'http://www6.clikpic.com/richardallen/images';
		break;
	}
		switch (server_id) {
		case 1:
		val = 'http://www1.clikpic.com/richardallen/images';
		break;
	}
		switch (server_id) {
		case 2:
		val = 'http://admin.clikpic.com/richardallen/images';
		break;
	}
		switch (server_id) {
		case 24:
		val = 'http://tpc15/clikpic/richardallen/images';
		break;
	}
		switch (server_id) {
		case 4:
		val = 'http://clikchurch.clikpic.com/richardallen/images';
		break;
	}
		switch (server_id) {
		case 5:
		val = 'http://www2.clikpic.com/richardallen/images';
		break;
	}
		switch (server_id) {
		case 22:
		val = 'http://tpc5/clikpic/richardallen/images';
		break;
	}
		switch (server_id) {
		case 23:
		val = 'http://tpc10/clikpic/richardallen/images';
		break;
	}
		switch (server_id) {
		case 25:
		val = 'http://tpc16/clikpic/richardallen/images';
		break;
	}
		switch (server_id) {
		case 26:
		val = 'http://tpc20/clikpic/richardallen/images';
		break;
	}
		switch (server_id) {
		case 40:
		val = 'http://www11.clikpic.com/richardallen/images';
		break;
	}
		switch (server_id) {
		case 42:
		val = 'db2.clikpic.com/richardallen/images';
		break;
	}
		switch (server_id) {
		case 15:
		val = 'http://www3.clikpic.com/richardallen/images';
		break;
	}
		switch (server_id) {
		case 18:
		val = 'http://www4.clikpic.com/richardallen/images';
		break;
	}
		switch (server_id) {
		case 19:
		val = 'http://www5.clikpic.com/richardallen/images';
		break;
	}
		switch (server_id) {
		case 31:
		val = 'http://www7.clikpic.com/richardallen/images';
		break;
	}
		switch (server_id) {
		case 32:
		val = 'http://admin2.clikpic.com/richardallen/images';
		break;
	}
		switch (server_id) {
		case 33:
		val = 'http://www8.clikpic.com/richardallen/images';
		break;
	}
		switch (server_id) {
		case 34:
		val = 'http://www9.clikpic.com/richardallen/images';
		break;
	}
		switch (server_id) {
		case 35:
		val = 'http://admin3.clikpic.com/richardallen/images';
		break;
	}
		switch (server_id) {
		case 37:
		val = 'http://admin4.clikpic.com/richardallen/images';
		break;
	}
		switch (server_id) {
		case 38:
		val = 'http://admin5.clikpic.com/richardallen/images';
		break;
	}
		switch (server_id) {
		case 39:
		val = 'http://www10.clikpic.com/richardallen/images';
		break;
	}
		switch (server_id) {
		case 50:
		val = '[cliktext value=article.servers_id type=servers_id]/richardallen/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 && backgrounds[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 = 'Richard Allen photography: ' + photoCaption;
			    }
        if (op.$detail.length > 0) {
      	temp = op.nextPhoto.fnGetImageDetails();
	    op.$detail.fadeGalleryDetails(temp, op.speed, function(){
			if (typeof(backgrounds) != 'undefined' && op.nextPhoto == backgrounds[op.nextPhoto.id]) {
				toggleAddToCartConfirm(backgrounds, op.$detail);
			} else if (typeof(photos) != 'undefined' && op.nextPhoto == photos[op.nextPhoto.id]) {
				toggleAddToCartConfirm(photos, op.$detail);
			}
			$('body').trigger('clikUpdate.popup');
	    });
    }
        $(op.$detailContainer).find('.replaceable[class*=replaceable_photo-]').each(function(){
    	var field = clik.getPrefixedClass(this.className, 'replaceable_photo-');
    	if (field in op.nextPhoto) {
    		$(this).fadeGalleryDetails(op.nextPhoto[field], op.speed);
    	}
    }).end().find('.replaceable.photoPayment').fadeGalleryDetails(op.nextPhoto.fnGetPaymentInfo(), op.speed, function(){
		if (typeof(backgrounds) != 'undefined' && op.nextPhoto == backgrounds[op.nextPhoto.id]) {
			toggleAddToCartConfirm(backgrounds, op.$detailContainer);
		} else if (typeof(photos) != 'undefined' && op.nextPhoto == photos[op.nextPhoto.id]) {
			toggleAddToCartConfirm(photos, op.$detailContainer);
		}
		$('body').trigger('clikUpdate.popup');
	});
		if (op.$photo.length > 0) {
		html = $('<img/>',{
			'class': 'mainphoto photo',
			src: photoSrc,
			id: 'mainPic',
			name: 'mainPic',
			width: op.nextPhoto.width,
			height: op.nextPhoto.height,
			alt: photoCaption,
			css: op.css || {}
		});
		if (op.href) {
			if (op.href.match(/<a/)) {
				html = $(op.href).append(html);
			} else {
				html = $('<a/>', {
					href: op.href,
					title: photoCaption
				}).append(html);
			}
		} else {
			html = $('<a/>', {
				title: photoCaption
			}).append(html);
		}
		if (op.speed == 0) {			op.$photo.html(html);			if (op.onBefore) {			  	op.onBefore.apply(op.$photo);			}			if (op.onAfter) {			  	op.onAfter.apply(op.$photo);			}		} else {			op.$photo.stop(true,true).fadeReplaceWith(html,op.speed,'',function(){  				if (op.onAfter) {				  	op.onAfter.apply(this);				}				clik.doColumnResize(false, $(this).add(op.$detail).add(op.$title));			}, op.onBefore);
		}	}
    if (op.field) {
		op.field.value = photoId;
	} else {
		op.$photo.data('image_id', photoId);
    }
        if (!op.speed) {
      	clik.doColumnResize(false, op.$photo.add(op.$detail).add(op.$title));
    }
        
    return html;
	}

/***************************************************************************
* Toggle add to cart confirmation element and set up the click event for   *
* the 'Add to cart' button.                                                *
***************************************************************************/
function toggleAddToCartConfirm(array, root){
	if (typeof(array) !== 'object' || array === null) {
	  	array = photos;
	}
	if (!$(root).length) {		root = $('body');	}	if($('#paymentConfirm', root).length > 0){
		$('#paymentConfirm', root).hide();
		$('#paymentAddButton', root)
		.unbind()
		.click(function(){
						form = $('#paymentForm', root)[0];
			option_id = 0;
			if(form.item_option.value){
				option_id = form.item_option.value;
			}
			if(addItemToBasket(form.item_number.value,array,form.site.value,parseInt(form.quantity.value, 10),option_id)){
				if($.browser.msie){$('#paymentConfirm', root).text('Item added to cart').show();}
				else{
					$('#paymentConfirm', root).text('Item added to cart').fadeIn();
					dspOrderDetails(form.site.value);
				}
			}
			else{
				$('#paymentConfirm', root).text('Item not added - check cookies are enabled in your browser.').fadeIn();
			}
		});
	}
}

/***************************************************************************
* Get payment info for image - add as 'method' to photo object             *
***************************************************************************/
clik.photo.fnGetImageDetails = function(){
	var temp = '';
	if (this.description != '') {
		temp +=  '<div id="imageDescription">' + this.description + '</div>';
	}
		if (this.photo_ref != '') {
		temp += '<div class="imageinfo" id="imageRef"><strong>Ref: </strong>' + this.photo_ref + '</div>';
	}
		if (this.takendate != '') {
		
		temp += '<div class="imageinfo" id="imageDate"><strong>Date: </strong>' + this.takendate + '</div>';
	}
	
	if (this.location != '') {
		
		temp += '<div class="imageinfo" id="imageLocation"><strong>Location: </strong>' +  this.location + '</div>';
	}
	
	if (this.photographer != '') {
		
		temp += '<div class="imageinfo" id="imagePhotographer"><strong>Photographer: </strong>' + this.photographer + '</div>';
	}
				
				if (temp != '') {
		temp += '<div class="spacer"></div>';
	}
	return temp;
};

/***************************************************************************
* Get payment info for image - add as 'method' to photo object             *
***************************************************************************/
clik.photo.fnGetPaymentInfo = function(){
	var temp = '';
	if (this.item_price !== '') {
				temp += '<p>Order this print:</p>';
				temp += '<div class="imageinfo" id="imagePrice"><strong>' + this.purchase_instruction + '</strong> ' + (this.item_price).toFixed(2) + '</div>';
		var item_name  = this.purchase_instruction;
		var amount = (this.item_price).toFixed(2);
		var item_option  = 0;
	}
	else if (this.payment_groups_id !== '') {
		temp += '<p>Buy this print online:</p>';
				temp += '<form id="paymentOptions" style="margin:0px;border:0px;" name="paymentOptions">';
											temp += '<select class="paymentlink" name="payment_options_id" onchange="updateItemValues($(this.form).next(\'#paymentForm\')[0],this.form.payment_options_id.options[this.form.payment_options_id.options.selectedIndex].value);">';
		
		temp += getPaymentOptions(this.payment_groups_id);
		temp += '</select>';
		temp += '</form>';
				var item_option  = paymentGroups[this.payment_groups_id].options[0];
		if(paymentOptions[item_option]){
			var item_name  = paymentOptions[item_option].payment_option;
			var amount =  paymentOptions[item_option].price;
		}
			}
	else {
		
	}
	if (this.item_price !== '' || this.payment_groups_id !== '') {
			temp += '<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({					href: thumbnails[imageID].fnGalleryLink(gallery_id),					title: galleries[gallery_id].title				});
			}
		}
	}
}

/***************************************************************************
* 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;
	}
}

			

