function thumbnail(g,e,b,f,d,a,c){this.id=g;this.galleries_id=e;this.caption=b;this.src=getServerPath(c)+"/"+f;this.width=d;this.height=a}function gallery(e,c,d,b,a){this.id=e;this.featured_images=c;this.title=d;this.section_code=b;this.photoIDs=a}var thumbnails=new Object();thumbnails[3536943]=new thumbnail(3536943,"","","oz_wedding_Lisa_BBG_thumb.JPG",130,87,1);thumbnails[3500656]=new thumbnail(3500656,"181226","Burghley House","Burghley House III1_thumb.JPG",87,130,1);thumbnails[2931253]=new thumbnail(2931253,"181226","Reaching the Sky","Singapore high risers low1_thumb.jpg",86,130,1);thumbnails[3030007]=new thumbnail(3030007,"181226","Town Hall","Leeds Town Hall III_thumb.JPG",76,130,1);thumbnails[6616790]=new thumbnail(6616790,"180371","A poppy in the rain, a moment of remembrance .... ","A_moment_of_remembrance_III_thumb.JPG",130,87,1);thumbnails[6616820]=new thumbnail(6616820,"180371","Poppy : a moment of remembrance ... ","A_moment_of_remembrance_2_III_thumb.JPG",130,87,1);thumbnails[6617268]=new thumbnail(6617268,"180371","Syriacus 'blue bird' Hibiscus I ...","Syriacus_Blue_Bird_Hibiscus_III_thumb.JPG",130,87,1);thumbnails[6617313]=new thumbnail(6617313,"180371","Syriacus 'blue bird' Hibiscus II ... ","Syriacus_Blue_Bird_Hibiscus_3_III_thumb.JPG",87,130,1);thumbnails[6617473]=new thumbnail(6617473,"180371","Syriacus 'blue bird' Hibiscus III ...","Syriacus_Blue_Bird_Hibiscus_III1_thumb.JPG",130,87,1);thumbnails[6663156]=new thumbnail(6663156,"180371","Dubai Leaf ... ","Dubai_Leaf_III_thumb.JPG",87,130,1);thumbnails[6664155]=new thumbnail(6664155,"180371","Pink Dhalia with a visitor","Dhalia_with_a_visitor_III_thumb.JPG",130,87,1);thumbnails[3030288]=new thumbnail(3030288,"180371","Osteospermum : Spoons","Flower III_thumb.JPG",130,87,1);thumbnails[3025972]=new thumbnail(3025972,"180371","Purple Passion","Single Purple flower dpp_thumb.JPG",130,87,1);thumbnails[3026068]=new thumbnail(3026068,"180371","Fine Lilac","fine lilac dpp_thumb.JPG",130,87,1);thumbnails[3438204]=new thumbnail(3438204,"180371","Fine Lilac II ... ","purple flower III_thumb.JPG",130,87,1);thumbnails[3659996]=new thumbnail(3659996,"180371","Rose","Weeping_rose_III_thumb.JPG",130,87,1);thumbnails[3025967]=new thumbnail(3025967,"180371","Rose with raindrops","Pink Rose with Raindrops dpp_thumb.JPG",87,130,1);thumbnails[3025962]=new thumbnail(3025962,"180371","Pretty in Pink","single pink rose dpp_thumb.JPG",87,130,1);thumbnails[3084937]=new thumbnail(3084937,"180371","Pink Passion","Pink Passion III_thumb.JPG",130,87,1);thumbnails[6394304]=new thumbnail(6394304,"180371","The President - Clematis","purple_AG_1_Doha_III_thumb.JPG",130,87,1);thumbnails[3042157]=new thumbnail(3042157,"180371","Gazanias","Gazanias III_thumb.JPG",87,130,1);thumbnails[6394548]=new thumbnail(6394548,"180371","Acacia","Acacia_III_thumb.JPG",130,87,1);thumbnails[3042597]=new thumbnail(3042597,"180371","Grass","Grass III_thumb.JPG",87,130,1);thumbnails[3684327]=new thumbnail(3684327,"180371","Orchid","Orchids_III_thumb.JPG",130,87,1);thumbnails[3050017]=new thumbnail(3050017,"180371","Dhalia","Dhalia III_thumb.JPG",130,87,1);thumbnails[3063006]=new thumbnail(3063006,"180371","Scabiosa caucasica ‘Stäfa’ I","Lilac Flower III_thumb.JPG",130,87,1);thumbnails[3684749]=new thumbnail(3684749,"180371","Scabiosa caucasica ‘Stäfa’ II","Lilac_flower_3_III_thumb.JPG",130,87,1);thumbnails[3684751]=new thumbnail(3684751,"180371","Scabiosa caucasica ‘Stäfa’ III","Lilac_flower_2_III_thumb.JPG",87,130,1);thumbnails[3684365]=new thumbnail(3684365,"180371","Bellis Pink & White","pink_light_daisy_III_thumb.JPG",130,87,1);thumbnails[6394595]=new thumbnail(6394595,"180371","Erica - Pink Star","Kew_Gardens_Flowers_1_Doha_III_thumb.JPG",87,130,1);thumbnails[3684241]=new thumbnail(3684241,"180371","Bellis Pink","daisy_III_Mar_09_thumb.JPG",130,87,1);thumbnails[3684273]=new thumbnail(3684273,"180371","Bellis Red","red_daisy_III_thumb.JPG",130,87,1);thumbnails[3084733]=new thumbnail(3084733,"180371","Field Flower","One Flower III_thumb.JPG",87,130,1);thumbnails[3084789]=new thumbnail(3084789,"180371","Petals of Love","Petals of love III_thumb.JPG",87,130,1);thumbnails[3684389]=new thumbnail(3684389,"180371","Pink, Pink, Pink","Refreshing_Pink_III_thumb.JPG",130,87,1);thumbnails[3063031]=new thumbnail(3063031,"180371","Echinacea Contemporary","Echinacea Contemporary III_thumb.JPG",130,87,1);thumbnails[3084714]=new thumbnail(3084714,"180371","Yellow Dhalia ","Bee on Flower III_thumb.JPG",130,87,1);thumbnails[3684397]=new thumbnail(3684397,"180371","Pond Lilly","Lilly__Fly_III_thumb.JPG",130,87,1);thumbnails[3684527]=new thumbnail(3684527,"180371","Deep Purple","purple_flower_with_white_background_III_thumb.JPG",130,87,1);thumbnails[3684531]=new thumbnail(3684531,"180371","Gerber Pink","Pink_Daisy_III_thumb.JPG",130,87,1);thumbnails[3084727]=new thumbnail(3084727,"180371","Gerbera : Orange","Orange Flower III_thumb.JPG",130,87,1);thumbnails[3472874]=new thumbnail(3472874,"180371","Lilly","Lilly III_thumb.JPG",130,87,1);thumbnails[3684535]=new thumbnail(3684535,"180371","Dhalia Pink","pink_dhalia_III_thumb.JPG",130,87,1);thumbnails[3684540]=new thumbnail(3684540,"180371","Dhalia Red","Red_Dhalia_Large_III_thumb.JPG",130,87,1);thumbnails[3684544]=new thumbnail(3684544,"180371","Dhalia Red II","Red_Dhalia_III_thumb.JPG",130,87,1);thumbnails[3026950]=new thumbnail(3026950,"181227","Escape","oz watsons bay look out 3_thumb.JPG",130,87,1);thumbnails[3042532]=new thumbnail(3042532,"181227","Curves of the Coast","Curves of Coast OZ III_thumb.JPG",130,87,1);thumbnails[3042545]=new thumbnail(3042545,"181227","Tranquility","Paradise III_thumb.JPG",130,98,1);thumbnails[3042494]=new thumbnail(3042494,"181227","Paradise Island","Paradise Island III_thumb.JPG",130,98,1);thumbnails[3085087]=new thumbnail(3085087,"181227","Sailing Boat","portrait sailing boat oz III_thumb.JPG",87,130,1);thumbnails[3084887]=new thumbnail(3084887,"181227","Race for Escape","Race for Escape III_thumb.JPG",130,87,1);thumbnails[3437294]=new thumbnail(3437294,"181227","Pebbles on the Beach","Newcastle Beach 6 III_thumb.JPG",130,87,1);thumbnails[3438147]=new thumbnail(3438147,"181227","Beachy","Rutland Water III_thumb.JPG",130,87,1);thumbnails[3437313]=new thumbnail(3437313,"181227","Gentle Tides","Newcastle Beach 2 III_thumb.JPG",130,87,1);thumbnails[3437314]=new thumbnail(3437314,"181227","Gentle Tides II","Newcastle Beach 3 III_thumb.JPG",130,87,1);thumbnails[3437350]=new thumbnail(3437350,"181227","Gentle Tides III","Newcastle Beach 5 III_thumb.JPG",130,87,1);thumbnails[3026983]=new thumbnail(3026983,"185647","Purple Mushrooms","purple mushrooms_thumb.JPG",87,130,1);thumbnails[6617652]=new thumbnail(6617652,"185647","13 The Lucky Unlucky ... the choice is yours!","13_The_Lucky_Unlucky_III_thumb.JPG",87,130,1);thumbnails[3017582]=new thumbnail(3017582,"185647","Blue Man","IMG_6634_2ddp2_thumb.JPG",87,130,1);thumbnails[3042210]=new thumbnail(3042210,"185647","Tribal Language","Tribal language III_thumb.JPG",87,130,1);thumbnails[3030043]=new thumbnail(3030043,"185647","Balls of Steel","balls of metal III_thumb.JPG",130,129,1);thumbnails[3084868]=new thumbnail(3084868,"185647","Stone","Stone III_thumb.JPG",87,130,1);thumbnails[6393666]=new thumbnail(6393666,"185647","swirling tea ...","Tea_III_thumb.JPG",130,87,1);thumbnails[3814046]=new thumbnail(3814046,"186125","Trees in the mist","burghley_tree_III_thumb.JPG",87,130,1);thumbnails[3814052]=new thumbnail(3814052,"186125","Chasing the mist","morning_mist_III_thumb.JPG",130,87,1);thumbnails[3814054]=new thumbnail(3814054,"186125","Burghley Woods","Burghley_Walk_trees_III_thumb.JPG",130,87,1);thumbnails[6616572]=new thumbnail(6616572,"186125","A low moon ... ","The_yellow_moon_III_thumb.JPG",130,87,1);thumbnails[6616590]=new thumbnail(6616590,"186125","Reach to the moon .... ","The_moon_III_thumb.JPG",130,90,1);thumbnails[6616591]=new thumbnail(6616591,"186125","Moon Gazing .... ","The_moon_5_III_thumb.JPG",130,87,1);thumbnails[6616594]=new thumbnail(6616594,"186125","Moon Gazing II .... ","The_moon_6_III_thumb.JPG",130,87,1);thumbnails[6394854]=new thumbnail(6394854,"186125","Betty's Bay Sunset","Bettys_bay_sunset_Doha_III_thumb.JPG",130,87,1);thumbnails[6394571]=new thumbnail(6394571,"186125","Blue Sky II","Blue_Sky_landscape_III_thumb.JPG",130,87,1);thumbnails[6394575]=new thumbnail(6394575,"186125","Blue Sky I","Blue_Sky_Portrait_III_thumb.JPG",87,130,1);thumbnails[6394578]=new thumbnail(6394578,"186125","Blue Sky III","Sky_and_Cloud_Portrait_III_thumb.JPG",87,130,1);thumbnails[3025949]=new thumbnail(3025949,"186125","Tree of Love","oz wedding garden scene bbg_thumb.JPG",91,130,1);thumbnails[3026076]=new thumbnail(3026076,"186125","Setting Sun","setting sun dpp_thumb.JPG",87,130,1);thumbnails[3026088]=new thumbnail(3026088,"186125","Water Objects","water objects dpp_thumb.JPG",87,130,1);thumbnails[6394054]=new thumbnail(6394054,"186125","Be still ... ","Richmond_Park_17_III_thumb.JPG",130,87,1);thumbnails[6394074]=new thumbnail(6394074,"186125","Red ... ","Richmond_Park_10_red_2_III1_thumb.JPG",87,130,1);thumbnails[6394101]=new thumbnail(6394101,"186125","simplicity ... ","Richmond_Park_12_white_fern2_III_thumb.JPG",87,130,1);thumbnails[6394108]=new thumbnail(6394108,"186125","Stepping Stones ... ","Richmond_Park_6_stones_III_thumb.JPG",87,130,1);thumbnails[6394127]=new thumbnail(6394127,"186125","Green Leaf ... ","Richmond_Park_2_III_thumb.JPG",130,87,1);thumbnails[6394164]=new thumbnail(6394164,"186125","Stalking Rory ... ","Rory_Lion_Addo_III_thumb.JPG",130,87,1);thumbnails[6394181]=new thumbnail(6394181,"186125","Looking for lunch .... Rory the Lion","Rory_Lion_Addo_2_III_thumb.JPG",130,87,1);thumbnails[6394206]=new thumbnail(6394206,"186125","A Duck's life ... ","Richmond_Park_4_ducks_III_thumb.JPG",87,130,1);thumbnails[3030477]=new thumbnail(3030477,"186125","Sky Vision","Sky III_thumb.JPG",130,87,1);thumbnails[3050182]=new thumbnail(3050182,"186125","Poppy views","Lanscape poppy view III_thumb.JPG",130,87,1);thumbnails[6394733]=new thumbnail(6394733,"186125","A Duck's Life II","Duck_1_Doha_III_thumb.JPG",130,87,1);thumbnails[3029681]=new thumbnail(3029681,"186125","Spiders ","spider III_thumb.JPG",130,87,1);thumbnails[3042191]=new thumbnail(3042191,"186125","Hay Hay","Hay III_thumb.JPG",130,87,1);thumbnails[3042208]=new thumbnail(3042208,"186125","Family Tree","Trees III_thumb.JPG",130,87,1);thumbnails[3042195]=new thumbnail(3042195,"186125","King of the Castle","King of the Castle III_thumb.JPG",130,87,1);thumbnails[3050341]=new thumbnail(3050341,"186125","Italian wheat fields","Italian wheat III_thumb.JPG",130,87,1);thumbnails[3084813]=new thumbnail(3084813,"186125","Piedmont, Italy","Italian Hills III_thumb.JPG",130,87,1);thumbnails[3684330]=new thumbnail(3684330,"186125","Rolling hills of Italy","Rolling_hills_of_Italy_III_thumb.JPG",130,87,1);thumbnails[3050414]=new thumbnail(3050414,"186125","Nights of drama","Nights drama III_thumb.JPG",130,87,1);thumbnails[3684519]=new thumbnail(3684519,"186125","Burghley Sunset","Sunset_III_thumb.JPG",87,130,1);thumbnails[3085113]=new thumbnail(3085113,"186125","Fishing","Fishing III_thumb.JPG",130,87,1);thumbnails[3684287]=new thumbnail(3684287,"186125","Peak District","Peak_district_tree_III_thumb.JPG",130,87,1);thumbnails[3437747]=new thumbnail(3437747,"186125","Sunset","Sunset AG III_thumb.JPG",130,87,1);thumbnails[3446215]=new thumbnail(3446215,"186125","Winter Sunrise","Winter Sunrise III_thumb.JPG",87,130,1);thumbnails[3446217]=new thumbnail(3446217,"186125","Winter Sunrise II","Winter Sunrise 2 III_thumb.JPG",130,87,1);thumbnails[3814049]=new thumbnail(3814049,"186125","Path of Love","burghley_path_of_love_III_thumb.JPG",87,130,1);thumbnails[3437368]=new thumbnail(3437368,"210085","Burj Al Arab","Burj al Arab III_thumb.JPG",130,86,1);thumbnails[3437468]=new thumbnail(3437468,"210085","Winter Arabian Skyline","Doha Skyline III_thumb.JPG",101,130,1);thumbnails[3437470]=new thumbnail(3437470,"210085","Arabian Carving ","Arabian Carving III_thumb.JPG",129,130,1);thumbnails[3437781]=new thumbnail(3437781,"210085","Arabian Dhow","Doha Dhow III_thumb.JPG",130,87,1);thumbnails[3078517]=new thumbnail(3078517,"210085","Camels","Follow me Camel III_thumb.JPG",130,87,1);thumbnails[6617567]=new thumbnail(6617567,"210138","Tiger Moth ... ","BBG_CA_SA_5_Tiger_Moth_III_BW_thumb.JPG",130,87,1);thumbnails[3437706]=new thumbnail(3437706,"210138","Engines ...faster, faster, faster ","Engines III_thumb.JPG",130,87,1);thumbnails[3078469]=new thumbnail(3078469,"210138","Tiger Moth","Tiger Moth III_thumb.JPG",130,87,1);thumbnails[3438137]=new thumbnail(3438137,"210138","Colourful Canoes","Canoe III_thumb.JPG",130,87,1);thumbnails[3446219]=new thumbnail(3446219,"210138","Winter Golf IV","Winter Golf 4 III_thumb.JPG",130,87,1);thumbnails[3446213]=new thumbnail(3446213,"210138","Winter Golf III","Winter Golf 3 III_thumb.JPG",130,87,1);thumbnails[3446204]=new thumbnail(3446204,"210138","Winter Golf","Winter Golf III_thumb.JPG",130,87,1);thumbnails[3446209]=new thumbnail(3446209,"210138","Winter Golf II","Winter Golf 2 III_thumb.JPG",130,87,1);thumbnails[3078685]=new thumbnail(3078685,"210138",'Vicky Brake "Looks Like Fun" @ Burghley Horse Trials 08',"Burghley Horse Trials 2 III_thumb.JPG",130,125,1);thumbnails[3084844]=new thumbnail(3084844,"210138",'Lucy Wiegersm "Beckli" : Burghley Horse Trials 08',"Lucy Wiegersma Burghley Horse Trials III_thumb.JPG",130,123,1);thumbnails[3084857]=new thumbnail(3084857,"210138",'Stuart Tinney "Vittorie" : Burghley Horse Trials 08',"Stuart Tinney Burghley Horse Trials 08 III_thumb.JPG",130,110,1);thumbnails[3029998]=new thumbnail(3029998,"210144","Peppers","peppers III cr_thumb.JPG",101,130,1);thumbnails[3085072]=new thumbnail(3085072,"210144","Basil","basil III_thumb.JPG",87,130,1);thumbnails[6616562]=new thumbnail(6616562,"210144","Spot the difference .... ","tomatoes_III_thumb.JPG",102,130,1);thumbnails[3456796]=new thumbnail(3456796,"211339","A private commission ...  ","In-situ image dining room III_thumb.JPG",87,130,1);thumbnails[3456799]=new thumbnail(3456799,"211339",'"Fine Lilac" brings the outside-in to this to this stairwell in a Town House',"in-situ image landing III_thumb.JPG",87,130,1);thumbnails[3813880]=new thumbnail(3813880,"211339",'"Grass" complements this modern mosaic bathroom',"bathroom_III_thumb.JPG",87,130,1);thumbnails[3813966]=new thumbnail(3813966,"211339",'"King of the Castle" adds humour and colour to cloakroom',"cloakroom_III_thumb.JPG",87,130,1);thumbnails[3813970]=new thumbnail(3813970,"211339",'A "Field Flower" look to a small cloakroom',"utility_cloak_room_III_thumb.JPG",87,130,1);thumbnails[3813971]=new thumbnail(3813971,"211339","A private commission ... ","puckje_bespoke_canvas_thumb.JPG",98,130,1);thumbnails[4829483]=new thumbnail(4829483,"211339",'"Gazanias" on Acrylic provides the accent colour in this modern living room',"Clares_after_2_III_thumb.JPG",87,130,1);thumbnails[6393434]=new thumbnail(6393434,"211339","A contemporary bathroom ...","bathroom_III_F9AAF772-24E8-5EC4-4FDF05480C3226CC_thumb.JPG",87,130,1);thumbnails[6617656]=new thumbnail(6617656,"211339",'"Pebbles on the Beach" framed for client\'s bathroom',"pebbles_in_Bathroom__thumb.JPG",98,130,1);thumbnails[4876887]=new thumbnail(4876887,"275905","Floral wall calendar 2010","Flower_Calendar_front_2010_III_thumb.jpg",130,92,1);thumbnails[4876888]=new thumbnail(4876888,"275905","Urban Desk Calendar 2010","Stamford_Desk_Calendar_front_III_thumb.JPG",130,69,1);var galleries=new Object();galleries[181226]=new gallery(181226,"2931253","Architecture Styles","gallery",[3500656,2931253,3030007]);galleries[180371]=new gallery(180371,"3030288","Nature's Touch","gallery",[6616790,6616820,6617268,6617313,6617473,6663156,6664155,3030288,3025972,3026068,3438204,3659996,3025967,3025962,3084937,6394304,3042157,6394548,3042597,3684327,3050017,3063006,3684749,3684751,3684365,6394595,3684241,3684273,3084733,3084789,3684389,3063031,3084714,3684397,3684527,3684531,3084727,3472874,3684535,3684540,3684544]);galleries[181227]=new gallery(181227,"3438147,3437350,3437314,3437313,3437294,3085087,3084887,3042545,3042532,3042494","Timeless Escapes","gallery",[3026950,3042532,3042545,3042494,3085087,3084887,3437294,3438147,3437313,3437314,3437350]);galleries[185647]=new gallery(185647,"6617652,6393666,3084868,3042210,3030043,3026983,3017582","Thought Provoking","gallery",[3026983,6617652,3017582,3042210,3030043,3084868,6393666]);galleries[186125]=new gallery(186125,"6616594,6616591,6616590,6616572,6394854,6394733,6394578,6394575,6394571,6394206","The Great Outdoors","gallery",[3814046,3814052,3814054,6616572,6616590,6616591,6616594,6394854,6394571,6394575,6394578,3025949,3026076,3026088,6394054,6394074,6394101,6394108,6394127,6394164,6394181,6394206,3030477,3050182,6394733,3029681,3042191,3042208,3042195,3050341,3084813,3684330,3050414,3684519,3085113,3684287,3437747,3446215,3446217,3814049]);galleries[210085]=new gallery(210085,"3437781,3437470,3437468,3437368,3078517","A World Away","gallery",[3437368,3437468,3437470,3437781,3078517]);galleries[210138]=new gallery(210138,"6617567,3446219,3446213,3446209,3446204,3438137,3437706,3084857,3084844,3078685","Wild at Heart","gallery",[6617567,3437706,3078469,3438137,3446219,3446213,3446204,3446209,3078685,3084844,3084857]);galleries[210144]=new gallery(210144,"6616562,3085072,3029998","Edible","gallery",[3029998,3085072,6616562]);galleries[211339]=new gallery(211339,"6617656,6393434,4829483,3813971,3813970,3813966,3813880,3456799,3456796","BBG Canvas Art : Interiors","gallery",[3456796,3456799,3813880,3813966,3813970,3813971,4829483,6393434,6617656]);galleries[275905]=new gallery(275905,"4876888,4876887","2010 Calendars","gallery",[4876887,4876888]);var imageSets=new Object();imageSets[1]="3026068";imageSets[2]="3030288,2931253";imageSets[3]="6664155,6663156,6617656,6617652,6617567,6617473,6617313,6617268,6616820,6616790,6616594,6616591,6616590,6616572,6616562,6394854,6394733,6394595,6394578,6394575,6394571,6394548,6394304,6394206,6394181,6394164,6394127,6394108,6394101,6394074,6394054,6393666,6393434,4876888,4876887,4829483,3814054,3814052,3814049,3814046,3813971,3813970,3813966,3813880,3684751,3684749,3684544,3684540,3684535,3684531";function randomListVal(a){arrayVals=a.split(",");if(arrayVals.length){pos=Math.round(Math.random()*(arrayVals.length-1));val=arrayVals[pos]}else{val=0}return val}function getServerPath(a){var b=-1;switch(a){case 21:b="http://www6.clikpic.com/BBG/images";break}switch(a){case 1:b="http://www1.clikpic.com/BBG/images";break}switch(a){case 2:b="http://admin.clikpic.com/BBG/images";break}switch(a){case 24:b="http://tpc15/clikpic/BBG/images";break}switch(a){case 4:b="http://www.clikchurch.com/BBG/images";break}switch(a){case 5:b="http://www2.clikpic.com/BBG/images";break}switch(a){case 22:b="http://tpc5/clikpic/BBG/images";break}switch(a){case 23:b="http://tpc10/clikpic/BBG/images";break}switch(a){case 25:b="http://tpc16/clikpic/BBG/images";break}switch(a){case 15:b="http://www3.clikpic.com/BBG/images";break}switch(a){case 18:b="http://www4.clikpic.com/BBG/images";break}switch(a){case 19:b="http://www5.clikpic.com/BBG/images";break}switch(a){case 31:b="http://www7.clikpic.com/BBG/images";break}switch(a){case 32:b="http://admin2.clikpic.com/BBG/images";break}switch(a){case 33:b="http://www8.clikpic.com/BBG/images";break}switch(a){case 34:b="http://www9.clikpic.com/BBG/images";break}switch(a){case 35:b="http://admin3.clikpic.com/BBG/images";break}switch(a){case 37:b="http://admin4.clikpic.com/BBG/images";break}return b}function showHomeImage(a){imageID=randomListVal("");if(!basic){a.src=photos[imageID].src;a.width=photos[imageID].width;a.height=photos[imageID].height}else{newImage=new Image(photos[imageID].width,photos[imageID].height);newImage.src=photos[imageID].src;document.images[a.name]=newImage}}function showHomeImageInline(){html="";imageID=randomListVal(imageSets[1]);if("gallery"!=""){if(backgrounds[imageID].galleries_id!=""){html+='<a href="'+backgrounds[imageID].section_code+"_"+backgrounds[imageID].galleries_id+'.html">'}else{html+='<a href="gallery.html">'}}html+='<img src="'+backgrounds[imageID].src+'" width="'+backgrounds[imageID].width+'" height="'+backgrounds[imageID].height+'" class="mainhomepageimage photo" id="mainSample" name="mainSample" alt="'+escape(backgrounds[imageID].caption)+'" border="0">';if("gallery"!=""){html+="</a>"}$("#homepageimage").html(html)}function getNextId(b,d,a){var c=getArrayPos(d,b);if(a){if(c==0){nextImgPos=d.length-1}else{nextImgPos=c-1}}else{if(c==d.length-1){nextImgPos=0}else{nextImgPos=c+1}}nextImg=d[nextImgPos];return nextImg}function next(d,b){var c=d.value;var a=galleries[photos[c].galleries_id].photoIDs;nextImg=getNextId(c,a);if(nextImg!=-1){updateImage(nextImg,d,b)}}function updateImage(f,e,b){if(!basic){document.getElementById("imagePhoto").innerHTML='<img class="mainphoto photo" src="'+photos[f].src+' " id="mainPic" name="mainPic" width="'+photos[f].width+'" height="'+photos[f].height+'" alt="'+photos[f].caption+'">';e.value=photos[f].id;$("#imageTitle").html(photos[f].caption);document.title="BBG Canvas Art: "+photos[f].caption;if(photos[f].caption==""){document.getElementById("imageTitle").style.display="none"}else{document.getElementById("imageTitle").style.display="block"}var a=fnGetImageDetails(f);if(a==""){document.getElementById("imageDetails").style.display="none";var c=document.getElementById("infoWrap");var d=document.getElementById("photoInfo");if(photos[f].caption==""){if(c!=null){c.className="empty"}if(d!=null){d.className="empty"}}else{if(c!=null){c.className="noinfo"}if(d!=null){d.className="noinfo"}}}else{document.getElementById("imageDetails").style.display="block";var c=document.getElementById("infoWrap");if(c!=null){c.className="normal"}var d=document.getElementById("photoInfo");if(d!=null){d.className="normal"}}document.getElementById("imageDetails").innerHTML=a;toggleAddToCartConfirm()}else{window.location="photo_"+photos[f].id+".html"}}function toggleAddToCartConfirm(){if($("#paymentConfirm").size()){$("#paymentConfirm").hide();$("#paymentAddButton").unbind().click(function(){form=document.getElementById("paymentForm");option_id=0;if(form.item_option.value){option_id=form.item_option.value}if(addItemToBasket(form.item_number.value,photos,form.site.value,parseInt(form.quantity.value,10),option_id)){if($.browser.msie){$("#paymentConfirm").text("Item added to cart").show()}else{$("#paymentConfirm").text("Item added to cart").fadeIn()}}else{$("#paymentConfirm").text("Item not added - check cookies are enabled in your browser.").fadeIn()}})}}function fnGetImageDetails(b){var a="";if(photos[b].description!=""){a=a+'<p id="imageDescription">'+photos[b].description+"</p>"}if(photos[b].photo_ref!=""){a=a+'<p class="imageinfo" id="imageRef"><strong>Ref: </strong>'+photos[b].photo_ref+"</p>"}if(photos[b].takendate!=""){a=a+'<p class="imageinfo" id="imageDate"><strong>Date: </strong>'+photos[b].takendate+"</p>"}if(photos[b].location!=""){a=a+'<p class="imageinfo" id="imageLocation"><strong>Location: </strong>'+photos[b].location+"</p>"}if(photos[b].photographer!=""){a=a+'<p class="imageinfo" id="imagePhotographer"><strong>Photographer: </strong>'+photos[b].photographer+"</p>"}a=a+fnGetPaymentInfo(photos[b]);if(a!=""){a=a+'<div class="spacer"></div>'}return a}function fnGetPaymentInfo(c){var b="";if(c.item_price!==""){b=b+"<p>Buy now using PayPal:</p>";b=b+'<p class="imageinfo" id="imagePrice"><strong>'+c.purchase_instruction+"</strong> 				&pound;"+(c.item_price).toFixed(2)+"</p>";var e=c.purchase_instruction;var d=(c.item_price).toFixed(2);var a=0}else{if(c.payment_groups_id!==""){b=b+"<p>Buy this print online:</p>";b=b+'<form id="paymentOptions" style="margin:0px;border:0px;" name="paymentOptions">';b=b+'<select class="paymentlink" name="payment_options_id" onchange="updateItemValues(document.forms.paymentForm,this.form.payment_options_id.options[this.form.payment_options_id.options.selectedIndex].value);">';b=b+getPaymentOptions(c.payment_groups_id);b=b+"</select>";b=b+"</form>";var a=paymentGroups[c.payment_groups_id].options[0];if(paymentOptions[a]){var e=paymentOptions[a].payment_option;var d=paymentOptions[a].price}}else{}}if(c.item_price!==""||c.payment_groups_id!==""){b=b+'<form id="paymentForm" style="margin:0px;border:0px;" name="paymentForm" target="_blank" action="https://www.paypal.com/cgi-bin/webscr" method="post">';b=b+'<input type="hidden" name="item_name" value="'+e+'">';ref="";if(c.photo_ref!=""){ref=c.photo_ref+" - "+c.caption}else{ref=c.id+" - "+c.caption}price=d;b=b+'<input type="hidden" name="cmd" value="_cart">';b=b+'<input type="hidden" name="business" value="info@bbgcanvasart.co.uk">';b=b+'<input type="hidden" name="currency_code" value="GBP">';b=b+'<input type="hidden" name="add" value="1">';b=b+'<input type="hidden" name="amount" value="'+d+'">';b=b+'<input type="hidden" name="item_number" value="'+ref+'">';b=b+'<input type="Submit" value="Add to cart" id="paymentAddButton" class="button" onmouseover="this.className=\'buttonHi\';" onmouseout="this.className=\'button\';">';b=b+"</form>";b=b+'<form id="paymentCartForm" style="margin:0px;" name="paymentCartForm" target="_blank" action="https://www.paypal.com/cgi-bin/webscr" method="post">';b=b+'<input type="hidden" name="cmd" value="_cart">';b=b+'<input type="hidden" name="business" value="info@bbgcanvasart.co.uk">';b=b+'<input type="hidden" name="display" value="1">';b=b+'<input type="Submit" value="View cart" id="paymentViewButton" class="button" onmouseover="this.className=\'buttonHi\';" onmouseout="this.className=\'button\';">';b=b+"</form>";b=b+'<div class="clearing">&nbsp;</div>'}return b}function previous(d,b){var c=d.value;var a=galleries[photos[c].galleries_id].photoIDs;nextImg=getNextId(c,a,1);if(nextImg!=-1){updateImage(nextImg,d,b)}}function showGalleryImage(c,b){imageID=randomListVal(galleries[c].featured_images);if(imageID!=0){b.src=thumbnails[imageID].src;b.width=thumbnails[imageID].width;b.height=thumbnails[imageID].height;if(b.width<130){var f=$("img#gallery"+c);f.parents(".thumbWrap").width(b.width);var a=f.siblings("h3").size()==1?f.siblings("h3"):f.parent(".thumbWrap").siblings("h3");var g=parseInt(a.css("padding-left"))+parseInt(a.css("padding-right"));var d=parseInt(a.css("border-left-width"))+parseInt(a.css("border-right-width"));var e=parseInt(f.parents(".thumbWrap").css("border-left-width"))+parseInt(f.parents(".thumbWrap").css("border-right-width"));a.width(f.outerWidth(true)-g-d+e)}}}function showGalleries(a){if(!basic){temp="";for(i=0;i<galleries.length;i++){if(galleries[i].id!=a){if(temp!=""){temp=temp+" | "}temp=temp+'<a href="gallery_'+galleries[i].id+'.html">'+galleries[i].title+"</a>"}}document.all.galleryLinks.innerHTML="Other galleries: "+temp}}function resizePhotoInfo(n){var b=$.extend({centre:false},n||{});var d=3;$("div#photoPanelOuter").height("auto");$("div#infoWrap").width(200);$("div#photoDetail").css("width","auto");var h=$("div#maincolContent").width();var j=$("div#photoWrap").outerWidth(true);var m=$("div#infoWrap").outerWidth(true);var k=$("div#photoWrap").outerHeight();var f=$("div#infoWrap").outerHeight();var c=$("div#infoWrap").hasClass("empty");floatDrop=0;var g=j;if(!c){if(h<(j+m)){floatDrop=1}if(!floatDrop){var a=$("div#infoWrap").innerWidth();$("div#infoWrap").width(a+(h-j-m-d));m=$("div#infoWrap").outerWidth(true);g=j+m;if(k>f){var e=$("div#photoPanelOuter").height();$("div#photoPanelOuter").height(e+(k-f));var f=$("div#infoWrap").outerHeight()}}else{var l=$("div#photoWrap").outerWidth();$("div#infoWrap").width(l)}}if(b.centre){$("div#photoDetail").width(g);$("div#photoDetail").css("margin-left","auto");$("div#photoDetail").css("margin-right","auto")}else{$("div#photoDetail").css("margin-left","0");$("div#photoDetail").css("margin-right","0")}}function getArrayPos(c,b){for(var a=0;a<c.length;a++){if(c[a]==b){return a}}return -1}function changeBgImg(a,e){var c=randomListVal(imageSets[e]);var d=backgrounds[c].src;var b=$(a);if(b.size()>0){if(/\bimg$/.test(a)){b.attr({src:d})}else{b.css({"background-image":'url("'+d+'")'})}}};