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[5426016]=new thumbnail(5426016,"","Daffodils","3_Daffodils_thumb.jpg",130,144,1);thumbnails[1021611]=new thumbnail(1021611,"44572","Heavy Metal","B1-Heavy-Metal-Music_thumb.jpg",130,118,1);thumbnails[5432358]=new thumbnail(5432358,"44572","Cloe","Chloe-2_thumb.jpg",130,195,1);thumbnails[5432333]=new thumbnail(5432333,"44572","Headphones","Headphones_PeterBaumber2010_thumb.jpg",130,82,1);thumbnails[1122822]=new thumbnail(1122822,"44572","Playing in Six Flats","B5-Played-in-6-Flats_thumb.jpg",130,84,1);thumbnails[5430460]=new thumbnail(5430460,"44572","Steve on Clarinet","190-copy1_thumb.jpg",130,163,1);thumbnails[1449313]=new thumbnail(1449313,"44572","Jazz Guitarist","B4-Jazz-Guitar_thumb.jpg",130,100,1);thumbnails[5432387]=new thumbnail(5432387,"43501","Cuban Street Musician","Cuban-Street-Musician_thumb.jpg",130,93,1);thumbnails[5432488]=new thumbnail(5432488,"43501","Rock & Roll","Rock--Roll_thumb.jpg",130,160,1);thumbnails[4295574]=new thumbnail(4295574,"43501","Classical Guitarist","Clasical-Guitar-003_thumb.jpg",130,172,1);thumbnails[5434672]=new thumbnail(5434672,"43501","Polished Brass","polished-brass-copy-72-ppi-copy_thumb.jpg",130,161,1);thumbnails[1071910]=new thumbnail(1071910,"43501","The Choirmaster<br>\r\n","The-Choirmaster_thumb.jpg",130,87,1);thumbnails[4295600]=new thumbnail(4295600,"43501","Elvis, (second of many)","DSC_2420-copy_thumb.jpg",130,251,1);thumbnails[608612]=new thumbnail(608612,"46697","Leader of the Pack","S1-Leader-of-the-Pack-MW_thumb.jpg",130,37,1);thumbnails[608581]=new thumbnail(608581,"46697","Eyes","S2-eyes-LMc_thumb.jpg",130,98,1);thumbnails[1022130]=new thumbnail(1022130,"46697","Crab Boat","S3-Crab-Boat-DL_thumb.jpg",130,43,1);thumbnails[3511882]=new thumbnail(3511882,"46697","Pair of Gannets trying to mate in flight","S4-A-pair-of-Gannets-flight-MW_thumb.jpg",130,98,1);thumbnails[1518479]=new thumbnail(1518479,"46697","Eighty Eight","S5-Eighty-Eight-PB_thumb.jpg",130,98,1);thumbnails[3511886]=new thumbnail(3511886,"46697","The Rider","S6-Rider-DL_thumb.jpg",130,94,1);thumbnails[620222]=new thumbnail(620222,"47466","The Heroine","C1-The_Heroine_thumb.jpg",130,196,1);thumbnails[577572]=new thumbnail(577572,"47466"," The York Pipers at the Guildhall","C3-york-pipers-perform-at-the-guldhall_thumb.jpg",130,105,1);thumbnails[3530697]=new thumbnail(3530697,"47466","Holly's Lead Singer","C2-Hollys-lead-singer_thumb.jpg",130,195,1);thumbnails[620227]=new thumbnail(620227,"47466","A Glass Musician in Prague","C4-the-glas-musician-of-prague_thumb.jpg",130,101,1);thumbnails[620220]=new thumbnail(620220,"47466","Military Band","C5-military-band_thumb.jpg",130,83,1);thumbnails[2666142]=new thumbnail(2666142,"47466","Cuban Melody","C6-Cuban_Melody_thumb.jpg",130,90,1);thumbnails[579884]=new thumbnail(579884,"44631","Up Hill Lincoln","Uphill-Lincoln-pinhole-1_thumb.jpg",130,119,1);thumbnails[579904]=new thumbnail(579904,"44631","PERFECT","Perfect-1_thumb.jpg",130,193,1);thumbnails[606311]=new thumbnail(606311,"44631","Up Hill Lincoln 2","Uphill-Lincoln-pinhole-2_thumb.jpg",130,117,1);thumbnails[649232]=new thumbnail(649232,"44631","Up Hill Lincoln","Uphill-Lincoln-1_thumb.jpg",130,98,1);thumbnails[733036]=new thumbnail(733036,"44631","Up Hill Lincoln","Uphill-Lincoln-2_thumb.jpg",130,173,1);thumbnails[733059]=new thumbnail(733059,"44631","UP HILL LINCOLN","Uphill-Lincoln-3_thumb.jpg",130,98,1);thumbnails[4943954]=new thumbnail(4943954,"281232","Willow Warbler","AP-Chiffchaff_thumb.jpg",130,98,1);thumbnails[4944000]=new thumbnail(4944000,"281232","Grey Wagtail","AP-Grey-wagtail_thumb.jpg",130,98,1);thumbnails[4944007]=new thumbnail(4944007,"281232","Long Tailed Tit","AP-Longtailed-tit_thumb.jpg",130,98,1);thumbnails[4944029]=new thumbnail(4944029,"281232","Pied Wagtail","AP-Pied-wagtail_thumb.jpg",130,98,1);thumbnails[4944048]=new thumbnail(4944048,"281232","Robin","AP-Robin_thumb.jpg",130,98,1);thumbnails[4944062]=new thumbnail(4944062,"281232","White Throat","AP-Whitethroat_thumb.jpg",130,98,1);thumbnails[4282405]=new thumbnail(4282405,"252856","1. Austin's day out (Left)","austins_day_out_1_copy_thumb.jpg",130,87,1);thumbnails[4282402]=new thumbnail(4282402,"252856","2. Austin's Day Out (Centre)","austins_day_out_2_copy_thumb.jpg",130,173,1);thumbnails[4282471]=new thumbnail(4282471,"252856","3. Austin's Day Out (Right)","austins_day_out_3_thumb.jpg",130,90,1);thumbnails[4282997]=new thumbnail(4282997,"252856","1. R.A.F. Aerobatic Team, The Red Arrows (Left)","RAF_Aerobatic_Team_Left_thumb.jpg",130,98,1);thumbnails[4282723]=new thumbnail(4282723,"252856","2. R.A.F. AEROBATIC TEAM, THE RED ARROWS (Centre)","RAF_Aerobatic_Team_Centre_thumb.jpg",130,98,1);thumbnails[4282521]=new thumbnail(4282521,"252856","3. R.A.F. Aerobatic Team, The Red Arrows (right)","RAF_Aerobatic_Team_Right__thumb.jpg",130,98,1);thumbnails[5272480]=new thumbnail(5272480,"296752","BLEA TARN, LAKE DISTRICT","12-Blea-Tarn-RWS_thumb.jpg",130,34,1);thumbnails[5276748]=new thumbnail(5276748,"296752","ROBIN","54-Robin-by-R-Symons_thumb.jpg",130,91,1);thumbnails[5272504]=new thumbnail(5272504,"296752","SHADES OF MIDNIGHT","86-Shades-of-Midnight-A-Elce_thumb.jpg",130,30,1);thumbnails[5272463]=new thumbnail(5272463,"296752","Bodium Castle","66-Bodium-Castle-Tont-Gaskins_thumb.jpg",130,88,1);thumbnails[5276771]=new thumbnail(5276771,"296752","Homeward Bound","24-Homeward-Bound_RWS_thumb.jpg",130,65,1);thumbnails[4943992]=new thumbnail(4943992,"296752","Perilous Descent","32-Perilous-Descent-by-A-Rosen_thumb.jpg",130,77,1);thumbnails[5284724]=new thumbnail(5284724,"296752","The Rider","62-The-Rider-D-Lavash_thumb.jpg",130,94,1);thumbnails[5284730]=new thumbnail(5284730,"296752","The Tourist","74-The-tourist-J-Whaler_thumb.jpg",130,98,1);thumbnails[5379623]=new thumbnail(5379623,"296752","Up, Up and Away","46-Up--Away-by-P-Baumber_thumb.jpg",130,98,1);thumbnails[4944017]=new thumbnail(4944017,"310098","Sandhill Cranes","Sanhill-Cranes-Linda-Graham-1st_thumb.jpg",130,102,1);thumbnails[4944054]=new thumbnail(4944054,"310098","Trumpet Squeeze","Trumpet-Squeeze-Karen-Harris-2nd_thumb.jpg",130,86,1);thumbnails[4944059]=new thumbnail(4944059,"310098","Elk","Elk-Karen-Harris-3rd_thumb.jpg",130,87,1);thumbnails[4944040]=new thumbnail(4944040,"310098","Renu Alex","Steve-Hike-Renu-Alex-HC_thumb.jpg",130,162,1);thumbnails[4943975]=new thumbnail(4943975,"310098","Night Sky","Abu-Chen-Night-Sky-C_thumb.jpg",130,87,1);thumbnails[4944068]=new thumbnail(4944068,"310098","Gorilla","Clark-Springman-Gorilla-C_thumb.jpg",130,162,1);thumbnails[1609808]=new thumbnail(1609808,"109559","Autumn","Autumn_thumb.jpg",130,86,1);thumbnails[1609804]=new thumbnail(1609804,"109559","Broken Fence","Broken_Fence_thumb.jpg",130,83,1);thumbnails[1609798]=new thumbnail(1609798,"109559","Gathering Storm over Bodium Castle","Gathering_Storm_Bodium_Castle_August_2009_thumb.jpg",130,83,1);thumbnails[1609815]=new thumbnail(1609815,"109559","Sunrise, Sutton on Sea","Dawn,-Sutton-on-Sea1_thumb.jpg",130,99,1);thumbnails[1609806]=new thumbnail(1609806,"109559","Gathering Storm WHITBY HARBOUR","Gathering_Storm_Whitby_Harbour_thumb.jpg",130,73,1);thumbnails[1619065]=new thumbnail(1619065,"109559","Remains of Sea Defences","Remains_of_sea_defences_Sutton-on-Sea_thumb.jpg",130,87,1);thumbnails[1525470]=new thumbnail(1525470,"109559","Stormy morning, Mablethorpe ","Stormy_Morning_Mablethorpe_thumb.jpg",130,87,1);thumbnails[1609794]=new thumbnail(1609794,"109559","Sunrise, Humber Mouth","Sunrise_Humber_Mouth_thumb.jpg",130,87,1);thumbnails[1619078]=new thumbnail(1619078,"109559","The Green Door","The_Green_Door_thumb.jpg",130,82,1);thumbnails[1525474]=new thumbnail(1525474,"109559","The Stream, Hubbard's Hill, Louth","The_Stream_Hubbards_Hills_thumb.jpg",130,83,1);thumbnails[1061555]=new thumbnail(1061555,"109559","The Weather Post","The_Weathered_Post_thumb.jpg",130,78,1);thumbnails[1619097]=new thumbnail(1619097,"109559","Thornton Abbey (HDR)","Thornton_Abbey_HDR_thumb.jpg",130,72,1);thumbnails[4325168]=new thumbnail(4325168,"254711","This is what brought the U.K. to a standstill.","snow-scene-JW_thumb.jpg",130,98,1);thumbnails[4325350]=new thumbnail(4325350,"254711","Lincoln Angels","xmas_cold_day_thumb.jpg",130,98,1);thumbnails[4325302]=new thumbnail(4325302,"254711","Lincoln Cathedtral & Castle Square","Xmas_white_christmas_thumb.jpg",130,98,1);thumbnails[4325397]=new thumbnail(4325397,"254711","Tupholme Abbey Lincolnshire","tuphome-abbey_thumb.jpg",130,87,1);thumbnails[5381329]=new thumbnail(5381329,"254711","A Cold Seat","-snow-0699-TH_thumb.jpg",130,86,1);thumbnails[5381123]=new thumbnail(5381123,"254711","Woodman's Cottage Lincoln","woodmans-cottage-Bag-Enderby-Lincs_thumb.jpg",130,98,1);thumbnails[4325231]=new thumbnail(4325231,"313620","Mellersain House","Mellersain-House_thumb.jpg",130,87,1);thumbnails[4325259]=new thumbnail(4325259,"313620","Bed Race","Bed-Race1_thumb.jpg",130,196,1);thumbnails[4325363]=new thumbnail(4325363,"313620","Steam Ploughing","Steam-Ploughing_thumb.jpg",130,87,1);thumbnails[4329848]=new thumbnail(4329848,"313620","Knaresborough","Knaresborough_thumb.jpg",130,87,1);thumbnails[5381446]=new thumbnail(5381446,"313620","Gate Keepers Cottage","Gate-Keepers-Cottage_thumb.jpg",130,87,1);thumbnails[4329871]=new thumbnail(4329871,"313620","The Winning Post","The-Wining-Post_thumb.jpg",130,87,1);thumbnails[604242]=new thumbnail(604242,"46391","RICHARD by Barbara Hill","Richard_thumb.jpg",130,177,1);thumbnails[1854033]=new thumbnail(1854033,"46391","Ami by Paul Bradley","ami_thumb.jpg",130,173,1);thumbnails[608602]=new thumbnail(608602,"46391","CLOE by Dave Lavash","Chloe-2_ED30BB7A-1D09-001F-99A25361673E6768_thumb.jpg",130,195,1);thumbnails[1854045]=new thumbnail(1854045,"46391","RICHARD by Jeff Milan","QE_IGP3901_thumb.jpg",130,189,1);thumbnails[4400148]=new thumbnail(4400148,"46391","Ami 2 By Paul Bradley","ami2_thumb.jpg",130,173,1);thumbnails[1854199]=new thumbnail(1854199,"46391","RICHARD by Jeff Milan","QE_IGP3908_thumb.jpg",130,175,1);thumbnails[4400196]=new thumbnail(4400196,"46391","Ami 3 by Paul Bradley","ami3_thumb.jpg",130,173,1);thumbnails[4441925]=new thumbnail(4441925,"46391","Clare 2 by Paul Bradley","clare_2_thumb.jpg",130,87,1);thumbnails[4441955]=new thumbnail(4441955,"46391","Clare by Paul Bradley","ami4_thumb.jpg",130,173,1);thumbnails[4441966]=new thumbnail(4441966,"46391","STEVE by Tony Houlden","190-copy_thumb.jpg",130,163,1);thumbnails[4911423]=new thumbnail(4911423,"46391","ROCK & ROLL by Alex rosen","Rock--Roll_ED38950F-1D09-001F-997E2642A1556EC8_thumb.jpg",130,160,1);thumbnails[4666714]=new thumbnail(4666714,"46391","Charles By Lester McKone","Studio_Lester_2_thumb.jpg",130,195,1);thumbnails[1378840]=new thumbnail(1378840,"57532","Perth Riverside","Perth riverside _thumb.jpg",130,86,1);thumbnails[1619009]=new thumbnail(1619009,"57532","In the Spotlight","In-the-spotlight-gold-BH_thumb.jpg",130,184,1);thumbnails[1525547]=new thumbnail(1525547,"57532","RAKED SAND","Raked-Sand--final_thumb.jpg",130,84,1);thumbnails[3024515]=new thumbnail(3024515,"57532","VENICE CARNIVAL","Venezia-carnivale_thumb.jpg",130,87,1);thumbnails[1619030]=new thumbnail(1619030,"57532","LATE NIGHT SHOPPER","LATE-NIGHT-SHOPPER_thumb.jpg",130,173,1);thumbnails[2059251]=new thumbnail(2059251,"57532","OUT OF SEASON","1-OUT-OF-SEASON-by-Dave-Lavash_thumb.jpg",130,87,1);var galleries=new Object();galleries[44572]=new gallery(44572,"5432358,5432333,5430460,1449313,1122822,1021611","MONO PRINT AWARDS","gallery",[1021611,5432358,5432333,1122822,5430460,1449313]);galleries[43501]=new gallery(43501,"5434672,5432488,5432387,4295600,4295574,1071910","COLOUR PRINT AWARDS","gallery",[5432387,5432488,4295574,5434672,1071910,4295600]);galleries[46697]=new gallery(46697,"3511886,3511882,1518479,1022130,608612,608581","PROJECTED IMAGE AWARDS","gallery",[608612,608581,1022130,3511882,1518479,3511886]);galleries[47466]=new gallery(47466,"3530697,2666142,620227,620222,620220,577572","DIGITAL AWARDS","gallery",[620222,577572,3530697,620227,620220,2666142]);galleries[44631]=new gallery(44631,"733059,733036,649232,606311,579904,579884","<strong>JOHN WHALER</strong>","gallery",[579884,579904,606311,649232,733036,733059]);galleries[281232]=new gallery(281232,"4944062,4944048,4944029,4944007,4944000,4943954","<strong>ANDREW PARSONS A.R.P.S.</strong>","gallery",[4943954,4944000,4944007,4944029,4944048,4944062]);galleries[252856]=new gallery(252856,"4282997,4282723,4282521,4282471,4282405,4282402","<strong>LPA POTY</strong>","gallery",[4282405,4282402,4282471,4282997,4282723,4282521]);galleries[296752]=new gallery(296752,"5379623,5284730,5284724,5276771,5276748,5272504,5272480,5272463,4943992","<strong>LCC NEBRASKA Awards to RBCC</strong>","gallery",[5272480,5276748,5272504,5272463,5276771,4943992,5284724,5284730,5379623]);galleries[310098]=new gallery(310098,"4944068,4944059,4944054,4944040,4944017,4943975","<strong>RBCC awards to LCC Nebraska</strong>","gallery",[4944017,4944054,4944059,4944040,4943975,4944068]);galleries[109559]=new gallery(109559,"1619097,1619078,1619065,1609815,1609808,1609806,1609804,1609798,1609794,1525474,1525470,1061555","<strong>TONY GASKINS</strong>","gallery",[1609808,1609804,1609798,1609815,1609806,1619065,1525470,1609794,1619078,1525474,1061555,1619097]);galleries[254711]=new gallery(254711,"5381329,5381123,4325397,4325350,4325302,4325168","<strong>LINCOLN IN THE SNOW</strong>","gallery",[4325168,4325350,4325302,4325397,5381329,5381123]);galleries[313620]=new gallery(313620,"5381446,4329871,4329848,4325363,4325259,4325231","Peter Lofthouse","gallery",[4325231,4325259,4325363,4329848,5381446,4329871]);galleries[46391]=new gallery(46391,"4911423,4666714,4441966,4441955,4441925,4400196,4400148,1854199,1854045,1854033,608602,604242","<strong>STUDIO GROUP</strong>","gallery",[604242,1854033,608602,1854045,4400148,1854199,4400196,4441925,4441955,4441966,4911423,4666714]);galleries[57532]=new gallery(57532,"3024515,2059251,1619030,1619009,1525547,1378840","<strong>EXHIBITIONS</strong>","gallery",[1378840,1619009,1525547,3024515,1619030,2059251]);var imageSets=new Object();imageSets[1]="5434672,5432488,5432387,5432358,5432333,5430460,5381446,5381329,5381123,5379623,5284730,5284724,5276771,5276748,5272504,5272480,5272463,4944068,4944062,4944059,4944054,4944048,4944040,4944029,4944017,4944007,4944000,4943992,4943975,4943954,4911423,4666714,4441966,4441955,4441925,4400196,4400148,4329871,4329848,4325397,4325363,4325350,4325302,4325259,4325231,4325168,4295600,4295574,4282997,4282723,4282521,4282471,4282405,4282402,3530697,3511886,3511882,3024515,2666142,2059251,1854199,1854045,1854033,1619097,1619078,1619065,1619030,1619009,1609815,1609808,1609806,1609804,1609798,1609794,1525547,1525474,1525470,1518479,1449313,1378840,1122822,1071910,1061555,1022130,1021611,733059,733036,649232,620227,620222,620220,608612,608602,608581,606311,604242,579904,579884,577572";imageSets[2]="5434672,5432488,5432387,5432358,5432333,5430460,5381446,5381329,5381123,5379623,5284730,5284724,5276771,5276748,5272504,5272480,5272463,4944068,4944062,4944059,4944054,4944048,4944040,4944029,4944017,4944007,4944000,4943992,4943975,4943954,4911423,4666714,4441966,4441955,4441925,4400196,4400148,4329871,4329848,4325397,4325363,4325350,4325302,4325259,4325231,4325168,4295600,4295574,4282997,4282723,4282521,4282471,4282405,4282402,3530697,3511886,3511882,3024515,2666142,2059251,1854199,1854045,1854033,1619097,1619078,1619065,1619030,1619009,1609815,1609808,1609806,1609804,1609798,1609794,1525547,1525474,1525470,1518479,1449313,1378840,1122822,1071910,1061555,1022130,1021611,733059,733036,649232,620227,620222,620220,608612,608602,608581,606311,604242,579904,579884,577572";imageSets[3]="5434672,5432488,5432387,5432358,5432333,5430460,5381446,5381329,5381123,5379623,5284730,5284724,5276771,5276748,5272504,5272480,5272463,4944068,4944062,4944059,4944054,4944048,4944040,4944029,4944017,4944007,4944000,4943992,4943975,4943954,4911423,4666714,4441966,4441955,4441925,4400196,4400148,4329871,4329848,4325397,4325363,4325350,4325302,4325259,4325231,4325168,4295600,4295574,4282997,4282723,4282521,4282471,4282405,4282402,3530697,3511886,3511882,3024515,2666142,2059251,1854199,1854045,1854033,1619097,1619078,1619065,1619030,1619009,1609815,1609808,1609806,1609804,1609798,1609794,1525547,1525474,1525470,1518479,1449313,1378840,1122822,1071910,1061555,1022130,1021611,620227,620222,620220,608612,608602,608581,604242,577572";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/rbcclub/images";break}switch(a){case 1:b="http://www1.clikpic.com/rbcclub/images";break}switch(a){case 2:b="http://admin.clikpic.com/rbcclub/images";break}switch(a){case 24:b="http://tpc15/clikpic/rbcclub/images";break}switch(a){case 4:b="http://www.clikchurch.com/rbcclub/images";break}switch(a){case 5:b="http://www2.clikpic.com/rbcclub/images";break}switch(a){case 22:b="http://tpc5/clikpic/rbcclub/images";break}switch(a){case 23:b="http://tpc10/clikpic/rbcclub/images";break}switch(a){case 25:b="http://tpc16/clikpic/rbcclub/images";break}switch(a){case 15:b="http://www3.clikpic.com/rbcclub/images";break}switch(a){case 18:b="http://www4.clikpic.com/rbcclub/images";break}switch(a){case 19:b="http://www5.clikpic.com/rbcclub/images";break}switch(a){case 31:b="http://www7.clikpic.com/rbcclub/images";break}switch(a){case 32:b="http://admin2.clikpic.com/rbcclub/images";break}switch(a){case 33:b="http://www8.clikpic.com/rbcclub/images";break}switch(a){case 34:b="http://www9.clikpic.com/rbcclub/images";break}switch(a){case 35:b="http://admin3.clikpic.com/rbcclub/images";break}switch(a){case 37:b="http://admin4.clikpic.com/rbcclub/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="'+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="RB CAMERA CLUB: "+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>"}if(a!=""){a=a+'<div class="spacer"></div>'}return a}function fnGetPaymentInfo(c){var b="";if(c.item_price!==""){b=b+"<p>Order this print:</p>";b=b+'<p class="imageinfo" id="imagePrice"><strong>'+c.purchase_instruction+"</strong> 							"+(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+'<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+'")'})}}};