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[3923358]=new thumbnail(3923358,"226965",'"Tulip Fantasy"<br>\r\n',"Tulip_FantasyDS_thumb.jpg",130,169,18);thumbnails[4049263]=new thumbnail(4049263,"64967","Salisbury Cathedral","Salisbury_CathedralDS_thumb.jpg",130,139,18);thumbnails[4766460]=new thumbnail(4766460,"","Leica Lens Cap Tropy 2008","Leica_Lenscap_Trophy_2008_thumb.jpg",130,95,18);thumbnails[4838776]=new thumbnail(4838776,"","Leica Fellowship M6 Trophy 2009 and Print","Oskar_Barnack_M6_Trophy_Winner_thumb.jpg",130,123,18);thumbnails[5435673]=new thumbnail(5435673,"64966","Traditional West Indies Schooner","West_Indies_sailing_schoonerDS_thumb.jpg",130,87,18);thumbnails[1115618]=new thumbnail(1115618,"226965","Australian Red Bottlebrush Flower","Australian-Red-Bottle-Brush_thumb.jpg",129,176,18);thumbnails[845009]=new thumbnail(845009,"64966","Pit Stop at 10,000 feet<br>\r\n<br>\r\n","Pit Stop at 10,000ft_thumb.jpg",130,97,18);thumbnails[2746276]=new thumbnail(2746276,"64967","The Empty Beach<br>\r\n","The Empty Beach!_thumb.jpg",130,85,18);thumbnails[3361866]=new thumbnail(3361866,"64966","Wide Boy!  ","Wide Boy!_thumb.jpg",130,69,18);thumbnails[3361919]=new thumbnail(3361919,"64967","The Grand Canyon1<br>\r\n","The Grand Canyon1_thumb.jpg",117,176,18);thumbnails[5425585]=new thumbnail(5425585,"64965","South American Blue Heron.   <br>\r\n","Blue_HeronDS_thumb.jpg",117,176,18);thumbnails[5428064]=new thumbnail(5428064,"65088","The Cleaner<br>\r\n","The_CleanerDS_thumb.jpg",88,176,18);thumbnails[6070134]=new thumbnail(6070134,"64965","Alert Nuthatch","Alert_NuthatchDHS_thumb.jpg",130,98,18);thumbnails[6383439]=new thumbnail(6383439,"226965",'"Seating Plan"',"Seating_PlanDHS_thumb.jpg",117,176,18);thumbnails[2966964]=new thumbnail(2966964,"64967",'"Canyon Roots"<br>\r\n',"Canyon Roots_thumb.jpg",130,52,18);thumbnails[845015]=new thumbnail(845015,"64966","RAF Jaguar Interceptor Fighter","Jaguar Fighter1_thumb.jpg",130,93,18);thumbnails[961566]=new thumbnail(961566,"226965","Magnolia","Magnolia_thumb.jpg",118,176,18);thumbnails[1853179]=new thumbnail(1853179,"64965",'"Cow Sea Lion with Pup and Foster Pup"',"Cow-sea-Lion-with-pup-and-f_thumb.jpg",130,93,18);thumbnails[3923340]=new thumbnail(3923340,"64967",'"Medieval Cloisters"',"Medieval_CloistersDS_thumb.jpg",130,87,18);thumbnails[5428070]=new thumbnail(5428070,"65088",'"Caribbean Sailor".<br>\r\n',"Caribbean_Sailor_thumb.jpg",117,176,18);thumbnails[6383460]=new thumbnail(6383460,"226965",'"Summer Sheen"',"Summer_SheenDHS_thumb.jpg",130,105,18);thumbnails[1410291]=new thumbnail(1410291,"64967",'"Autumn in Snowdonia"',"Autumn-in-Snowdonia1_thumb.jpg",130,95,18);thumbnails[845024]=new thumbnail(845024,"64966","Escort Agency!","Escort Agency!_thumb.jpg",130,92,18);thumbnails[1645205]=new thumbnail(1645205,"64967","Cradle Mountain","Cradle Mountain, Tasmania_thumb.jpg",130,87,18);thumbnails[3361927]=new thumbnail(3361927,"64967","The Grand Canyon2","The Grand Canyon2_thumb.jpg",130,76,18);thumbnails[5428236]=new thumbnail(5428236,"65088","Fisherman of St. Lucia<br>\r\n","Fisherman_of_St_Lucia_DS_thumb.jpg",130,101,18);thumbnails[5428239]=new thumbnail(5428239,"64965","White Fallow Deer Buck<br>\r\n","White_Fallow_Deer_BuckDS_thumb.jpg",130,95,18);thumbnails[6070167]=new thumbnail(6070167,"64965","Forest Nuthatch","Forest_NuthatchDHS_thumb.jpg",130,130,18);thumbnails[847382]=new thumbnail(847382,"65088","Nodding Off","Nodding Off_thumb.jpg",130,173,18);thumbnails[851917]=new thumbnail(851917,"64967","Sky Tower","Sky Tower, Aukland, New Zealand_thumb.jpg",130,173,18);thumbnails[890380]=new thumbnail(890380,"64966","RAF Tornado at 22,000 feet","Tornado ground attack fighter_thumb.jpg",130,92,18);thumbnails[890406]=new thumbnail(890406,"64966"," 1917 Sopwith Triplane (flying replica)","Sopwith Triplane (Replica)_thumb.jpg",130,93,18);thumbnails[5428058]=new thumbnail(5428058,"64965","Scarlet Ibis[Eudocimus Ruber]<br>\r\n<br>\r\n","Scarlet_Ibis_Eudicimus_ruberDS_thumb.jpg",130,87,18);thumbnails[1945549]=new thumbnail(1945549,"64965","Bull Sea Lion selecting Mate","Bull Sea Lion selecting Mate_thumb.jpg",130,93,18);thumbnails[4746999]=new thumbnail(4746999,"65088",'"Brief Encounter"  ',"Brief-Encounter1_thumb.jpg",117,176,18);thumbnails[842832]=new thumbnail(842832,"65088","Young Kim","Young Kim copy_thumb.jpg",130,168,18);thumbnails[851850]=new thumbnail(851850,"64967","Douro River","Douro River, Oporto_thumb.jpg",130,81,18);thumbnails[853004]=new thumbnail(853004,"64965","Mature Female Barbary Ape with Infant","Female Barbary (Rock) Ape with Infant2_thumb.jpg",130,166,18);thumbnails[866783]=new thumbnail(866783,"64966","R.A.F.Tornado re-fuelling in flight","Tornado in flight re-fuelling_thumb.jpg",130,92,18);thumbnails[890287]=new thumbnail(890287,"64966","America's Cup Winner ","America's Cup Winner, Auckland_thumb.jpg",130,173,18);thumbnails[1853191]=new thumbnail(1853191,"64965","Old Salt Water Crocodile","Old Salt Water Crocodile_thumb.jpg",130,98,18);thumbnails[1115633]=new thumbnail(1115633,"64966","Wing Walking Duet","Wing-Walking-Duet_thumb.jpg",130,93,18);thumbnails[848761]=new thumbnail(848761,"65088","Seat of Study","Seat of Studies_thumb.jpg",111,176,18);thumbnails[1000340]=new thumbnail(1000340,"64967","Spinnaker Web","Spinnaker-Web1_thumb.jpg",130,173,18);thumbnails[1947002]=new thumbnail(1947002,"64967",'"Pioneer\'s Wagon Wheel"',"Pioneering Wagon Wheel_thumb.jpg",130,174,18);thumbnails[851825]=new thumbnail(851825,"64967","Early Morning Slipway","Early Morning Slipway_thumb.jpg",130,99,18);thumbnails[1853186]=new thumbnail(1853186,"64965","Young Salt Water Crocodile jumping for Prey","Salt-water-Crocodile-jumpin_thumb.jpg",126,176,18);thumbnails[3330040]=new thumbnail(3330040,"64967","Wintry River Test","River Test in Winter_thumb.jpg",130,83,18);thumbnails[5428163]=new thumbnail(5428163,"65088","Ralph<br>\r\n","Ralph_Flight_Lieutenant_RAF_DS_thumb.jpg",117,176,18);thumbnails[1410519]=new thumbnail(1410519,"65088",'"Boy Band"',"Boy-Band[dhs-web]_thumb.jpg",130,173,18);thumbnails[1945561]=new thumbnail(1945561,"64967","Retired but not Forgotten","Retired but not Forgotten_thumb.jpg",130,102,18);thumbnails[2565678]=new thumbnail(2565678,"64967",'"Gone and Forgotten"',"Gone-and-Forgotten_thumb.jpg",130,87,18);thumbnails[1000356]=new thumbnail(1000356,"64967","Venetian Street Light","Venice-Street-Light_thumb.jpg",130,173,18);thumbnails[1853205]=new thumbnail(1853205,"64965","South Australian Pelicans","South-Australian-Pelicans_thumb.jpg",117,176,18);thumbnails[4099851]=new thumbnail(4099851,"65088","Winnie arrives by train.","Winnie_arrives_by_trainDS_thumb.jpg",124,176,18);thumbnails[888810]=new thumbnail(888810,"65088","Doug Gregory - Veteran Aviator and Octagenarian","Doug Gregory - Veteran Aviator_thumb.jpg",130,98,18);thumbnails[961613]=new thumbnail(961613,"64965","Marwell Tiger","Marwell Tiger_thumb.jpg",130,87,18);thumbnails[844113]=new thumbnail(844113,"64967","Crossing the Lagoon","Crossing Venice Lagoon3_thumb.jpg",130,98,18);thumbnails[3536359]=new thumbnail(3536359,"64965",'"Aggressive Eagle Owl" <br>\r\n',"Aggressive_Eagle_Owl_Dweb_thumb.jpg",130,152,18);thumbnails[4099828]=new thumbnail(4099828,"65088","Anglo-American relations","Anglo-American_relations_thumb.jpg",111,176,18);thumbnails[4391481]=new thumbnail(4391481,"64967",'"For Queen and Country"',"For_Queen_and_Country_thumb.jpg",130,93,18);thumbnails[4926810]=new thumbnail(4926810,"64965","Fallow Deer at the Rut ","Fallow_Deer_at_the_Rut_Stand_thumb.jpg",117,176,18);thumbnails[6070149]=new thumbnail(6070149,"64966","Antonov AN2 on Finals at Kemble","Antonov_AN2_on_finalsDHS_thumb.jpg",130,87,18);thumbnails[848790]=new thumbnail(848790,"65088","The Skipper","The Skipper_thumb.jpg",130,98,18);thumbnails[1945598]=new thumbnail(1945598,"64965","Koala Contemplation","Koala Contemplation_thumb.jpg",113,176,18);thumbnails[4391485]=new thumbnail(4391485,"64967","Winchester Cathedral","Winchester_Cathedral_BWC_thumb.jpg",130,163,18);thumbnails[4926833]=new thumbnail(4926833,"64965","Fallow Deer in Autumn","Fallow_Deer_in_Autumn_thumb.jpg",130,87,18);thumbnails[6070157]=new thumbnail(6070157,"64966","Re-fuelling the AN2 at Kemble","Re-fuelling_the_Antonov_AN2_at_KembleDHS_thumb.jpg",130,87,18);thumbnails[4391503]=new thumbnail(4391503,"65088",'"Silver Hands"',"Silver_Handsds_thumb.jpg",130,93,18);thumbnails[4926823]=new thumbnail(4926823,"64965","Young Fallow Deer","Togetherness_thumb.jpg",130,87,18);thumbnails[4503623]=new thumbnail(4503623,"64965","Elderly Painted Lady","Elderly_Painted_Lady_thumb.jpg",130,108,18);thumbnails[4928140]=new thumbnail(4928140,"64965","White Fallow Deer Buck","Fallow_Deer_Buck_at_Rut_timeDS_thumb.jpg",130,91,18);thumbnails[1000483]=new thumbnail(1000483,"64967","Bridge of Sigh's, Venice, Italy","Bridge-of-Sighs_thumb.jpg",130,98,18);thumbnails[2438908]=new thumbnail(2438908,"64965","East Mediterranean Gull","East-Mediterranean-Gull_thumb.jpg",130,102,18);thumbnails[848954]=new thumbnail(848954,"64965","Young Female Barbary Ape","Female Barbary Ape_thumb.jpg",123,176,18);thumbnails[1000414]=new thumbnail(1000414,"64967","A Burano House","BuranoHouse_thumb.jpg",115,176,18);thumbnails[3010451]=new thumbnail(3010451,"64967",'"Bridge of Sigh\'s", Oxford, U.K.',"Bridge of Sighs, Oxford U_thumb.K..jpg",130,93,18);thumbnails[1115651]=new thumbnail(1115651,"64967","The Amelfi Coast from Ravello","Amelfi-Coast-from-Ravello_thumb.jpg",130,96,18);var galleries=new Object();galleries[64966]=new gallery(64966,"6070157,6070149,5435673,3361866,1115633,890406,890380,890287,866783,845024","Air, Sea & Land Transport","section94036",[5435673,845009,3361866,845015,845024,890380,890406,866783,890287,1115633,6070149,6070157]);galleries[64967]=new gallery(64967,"844113","City, Sea and Landscapes","section94046",[4049263,2746276,3361919,2966964,3923340,1410291,1645205,3361927,851917,851850,1000340,1947002,851825,3330040,1945561,2565678,1000356,844113,4391481,4391485,1000483,1000414,3010451,1115651]);galleries[226965]=new gallery(226965,"6383460,6383439,3923358,1115618,961566","Gardens & Flowers","section277681",[3923358,1115618,6383439,961566,6383460]);galleries[65088]=new gallery(65088,"5428236,5428163,5428070,5428064,4746999,4391503,4099851,4099828,1410519,888810","People","section94244",[5428064,5428070,5428236,847382,4746999,842832,848761,5428163,1410519,4099851,888810,4099828,848790,4391503]);galleries[64965]=new gallery(64965,"6070167,6070134,5428239,5428058,5425585,4928140,4926833,4926823,4926810,4503623","The Natural World","section94045",[5425585,6070134,1853179,5428239,6070167,5428058,1945549,853004,1853191,1853186,1853205,961613,3536359,4926810,1945598,4926833,4926823,4503623,4928140,2438908,848954]);var imageSets=new Object();imageSets[1]="6383460,6383439,6070167,6070157,6070149,6070134,5435673,5428239,5428236,5428163,5428070,5428064,5428058,5425585,4928140,4926833,4926823,4926810,4838776,4766460,4746999,4503623,4391503,4391485,4391481,4099851,4099828,4049263,3923358,3923340,3536359,3361927,3361919,3361866,3330040,3010451,2966964,2746276,2565678,2438908,1947002,1945598,1945561,1945549,1853205,1853191,1853186,1853179,1645205,1410519";imageSets[2]="844113";imageSets[3]="6383460,6383439,6070167,6070157,6070149,6070134,5435673,5428239,5428236,5428163,5428070,5428064,5428058,5425585,4928140,4926833,4926823,4926810,4838776,4766460,4746999,4503623,4391503,4391485,4391481,4099851,4099828,4049263,3923358,3923340,3536359,3361927,3361919,3361866,3330040,3010451,2966964,2746276,2565678,2438908,1947002,1945598,1945561,1945549,1853205,1853191,1853186,1853179,1645205,1410519";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/dhsimmonds/images";break}switch(a){case 1:b="http://www1.clikpic.com/dhsimmonds/images";break}switch(a){case 2:b="http://admin.clikpic.com/dhsimmonds/images";break}switch(a){case 24:b="http://tpc15/clikpic/dhsimmonds/images";break}switch(a){case 4:b="http://www.clikchurch.com/dhsimmonds/images";break}switch(a){case 5:b="http://www2.clikpic.com/dhsimmonds/images";break}switch(a){case 22:b="http://tpc5/clikpic/dhsimmonds/images";break}switch(a){case 23:b="http://tpc10/clikpic/dhsimmonds/images";break}switch(a){case 25:b="http://tpc16/clikpic/dhsimmonds/images";break}switch(a){case 15:b="http://www3.clikpic.com/dhsimmonds/images";break}switch(a){case 18:b="http://www4.clikpic.com/dhsimmonds/images";break}switch(a){case 19:b="http://www5.clikpic.com/dhsimmonds/images";break}switch(a){case 31:b="http://www7.clikpic.com/dhsimmonds/images";break}switch(a){case 32:b="http://admin2.clikpic.com/dhsimmonds/images";break}switch(a){case 33:b="http://www8.clikpic.com/dhsimmonds/images";break}switch(a){case 34:b="http://www9.clikpic.com/dhsimmonds/images";break}switch(a){case 35:b="http://admin3.clikpic.com/dhsimmonds/images";break}switch(a){case 37:b="http://admin4.clikpic.com/dhsimmonds/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("section94244"!=""){if(backgrounds[imageID].galleries_id!=""){html+='<a href="'+backgrounds[imageID].section_code+"_"+backgrounds[imageID].galleries_id+'.html">'}else{html+='<a href="section94244.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("section94244"!=""){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="David Simmonds Photography: "+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>David H Simmonds </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> 				&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="">';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="">';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+'")'})}}};