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[2487498]=new thumbnail(2487498,"159639","bird tryptych","3D_FRAMEbabybirds21_thumb.jpg",130,92,32);thumbnails[2487499]=new thumbnail(2487499,"159639","blue tit parent","DSC_0006bluetit2_thumb.jpg",130,107,32);thumbnails[2487502]=new thumbnail(2487502,"159639","wild buzzard","DSC_0009bjuzzard_thumb.jpg",130,121,32);thumbnails[2487508]=new thumbnail(2487508,"159639","Male Chaffinch","DSC_0082malechaff1_thumb.jpg",130,96,32);thumbnails[2487509]=new thumbnail(2487509,"159639","Canada Goose washing","DSC_0113canadageese2_thumb.jpg",130,91,32);thumbnails[2487513]=new thumbnail(2487513,"159639","Fledgling blue tit","fledgelingbluetit_thumb.jpg",130,86,32);thumbnails[2487541]=new thumbnail(2487541,"159639","Robin","robin frameandcaption1_thumb.jpg",130,118,32);thumbnails[2487597]=new thumbnail(2487597,"159640","Flower tryptych","3flowers1_thumb.jpg",130,92,32);thumbnails[2487601]=new thumbnail(2487601,"159641","grey squirrel","DSC_0015squirrel_thumb.jpg",130,86,32);thumbnails[2487603]=new thumbnail(2487603,"159641","wood mouse","DSC_0055mouse1_thumb.jpg",130,86,32);thumbnails[2487605]=new thumbnail(2487605,"159641","otter","otter1_thumb.jpg",130,89,32);thumbnails[2487606]=new thumbnail(2487606,"159641","Ginger cat","GINGER2_thumb.jpg",130,116,32);thumbnails[2487612]=new thumbnail(2487612,"159642","River walk","autumn walk_thumb.jpg",86,130,32);thumbnails[2491384]=new thumbnail(2491384,"159640","Red rose 2","DSC_0007rose2_thumb.jpg",130,86,32);thumbnails[2491389]=new thumbnail(2491389,"159640","red on blue","DSC_0030poppies_thumb.jpg",130,91,32);thumbnails[2491390]=new thumbnail(2491390,"159640","red on grey","redpoppiesongrey_thumb.jpg",130,91,32);thumbnails[2491391]=new thumbnail(2491391,"159642","Any barn in a storm","Any barn in a storm_thumb.jpg",130,86,32);thumbnails[2491395]=new thumbnail(2491395,"159642","The cider orchard","ciderorchard_thumb.jpg",130,86,32);thumbnails[2491399]=new thumbnail(2491399,"159642","Torbryan church","DSC_0007Torbryanchurch1_thumb.jpg",130,94,32);thumbnails[2495649]=new thumbnail(2495649,"159641","Peacock butterfly","DSC_0006flutterby_thumb.jpg",130,83,32);thumbnails[2495701]=new thumbnail(2495701,"159640","poppies","DSC_0005_thumb.jpg",130,86,32);thumbnails[2495718]=new thumbnail(2495718,"159640","Californian poppies","DSC_0036yellowpoppy_thumb.jpg",130,86,32);thumbnails[2495744]=new thumbnail(2495744,"159640","Single californian poppy","DSC_0042crop_thumb.jpg",130,127,32);thumbnails[2495748]=new thumbnail(2495748,"159640","Red rose","DSC_0058rose1_thumb.jpg",130,86,32);thumbnails[2864164]=new thumbnail(2864164,"159639","Nuthatch","DSC_0123nuthatchclikpic_thumb.jpg",130,91,32);thumbnails[3508232]=new thumbnail(3508232,"159639","Black-necked Stilt","black-necked stilt clikpic_thumb.jpg",130,101,32);thumbnails[3517746]=new thumbnail(3517746,"159641","Nosey","Seal noseclikpic_thumb.jpg",130,86,32);thumbnails[3517755]=new thumbnail(3517755,"159641","Fur Seal","fur seal 2clik_thumb.jpg",130,86,32);thumbnails[3517756]=new thumbnail(3517756,"159639","Inca Tern","Inca tern1clik_thumb.jpg",97,130,32);thumbnails[3579069]=new thumbnail(3579069,"159639","Avocet","DSC_0038Avocet1clik_thumb.jpg",90,130,32);thumbnails[3579120]=new thumbnail(3579120,"159639","Black-necked Stilt 5","DSC_0044blacknecked_stiltclik_thumb.jpg",94,130,32);thumbnails[3620936]=new thumbnail(3620936,"159641","Female squirrel","DSC_0056_2female_squirrelclik_thumb.jpg",130,93,32);thumbnails[3622381]=new thumbnail(3622381,"159639","common buzzard (3)","DSC_0120_2common_buzzard_3clik_thumb.jpg",99,130,32);thumbnails[3874206]=new thumbnail(3874206,"159639","Fledgling blue tit","babybluetitclik_thumb.jpg",93,130,32);thumbnails[3879610]=new thumbnail(3879610,"159639","Great Spotted Woodpecker","DSC_0137woodpecker2clikpic_thumb.jpg",92,130,32);thumbnails[4098056]=new thumbnail(4098056,"159639","young starling","DSC_0056young_starlingclik_thumb.jpg",130,85,32);thumbnails[4257239]=new thumbnail(4257239,"159639","Swan and reflection","DSC_0044_2nd_go_at_swanclik_thumb.jpg",130,86,32);thumbnails[4410809]=new thumbnail(4410809,"159641","Pair of otters","243_pr_ottersclik_thumb.jpg",130,86,32);thumbnails[4410816]=new thumbnail(4410816,"159641","You lookin' at me?","DSC_0130you_looking_at_meclik_thumb.jpg",130,91,32);thumbnails[4410824]=new thumbnail(4410824,"159641","I can see you!","DSC_0137otter_3clik_thumb.jpg",130,86,32);thumbnails[4410828]=new thumbnail(4410828,"159641","otter","DSC_0181otter_1clik_thumb.jpg",130,86,32);thumbnails[4410835]=new thumbnail(4410835,"159641","Swallowtail butterfly","DSC_0275black_swallowtailclik_thumb.jpg",130,90,32);thumbnails[4547390]=new thumbnail(4547390,"159639","Frazzled blue tit","frazzled_adultclik_thumb.jpg",130,86,32);thumbnails[4857981]=new thumbnail(4857981,"159640","orange rose","DSC_0113full_orange_roseclik_thumb.jpg",130,86,32);thumbnails[4857987]=new thumbnail(4857987,"159640","orange rose 2","DSC_0151orange_rose1clik_thumb.jpg",86,130,32);thumbnails[4999845]=new thumbnail(4999845,"159641","Young Alpaca","NLM_0273alpaca2clik_thumb.jpg",130,86,32);thumbnails[4999851]=new thumbnail(4999851,"159641","Dragonfly","NLM_0199Southern_Hawker_clik_thumb.jpg",130,86,32);thumbnails[5122806]=new thumbnail(5122806,"159642","Smoke over Torbryan church","smoke2clik_thumb.jpg",130,98,32);thumbnails[5122811]=new thumbnail(5122811,"159642","A good book","DSC_0102a_good_book_2clik_thumb.jpg",98,130,32);thumbnails[5122830]=new thumbnail(5122830,"159639","Coming in to land","DSC_0093coming_in_to_landclik_thumb.jpg",130,95,32);thumbnails[5310836]=new thumbnail(5310836,"308195","abstract number1","NLM_0039abstracted_rosefractaliusclik_thumb.jpg",130,91,32);thumbnails[5312920]=new thumbnail(5312920,"308195","Abstract two","abstract_two_clik_thumb.jpg",130,91,32);thumbnails[5312957]=new thumbnail(5312957,"308195","Abstract three","abstract_three_clik_thumb.jpg",130,101,32);thumbnails[5394989]=new thumbnail(5394989,"308195","Abstract five","abstract_fiveclik_thumb.jpg",130,86,32);thumbnails[5394995]=new thumbnail(5394995,"308195","Abstract four","abstract_fourclik_thumb.jpg",130,86,32);thumbnails[5395000]=new thumbnail(5395000,"308195","Abstract six","abstract_sixclik_thumb.jpg",130,86,32);thumbnails[5395005]=new thumbnail(5395005,"308195","Eye of the world","eye_of_the_worldclik_thumb.jpg",130,86,32);thumbnails[5395007]=new thumbnail(5395007,"308195","spider's web","fractalspider_ripple_thumb.jpg",130,86,32);thumbnails[5395011]=new thumbnail(5395011,"308195","Garlic fractal","garlic_fractalclik_thumb.jpg",130,90,32);thumbnails[5395013]=new thumbnail(5395013,"308195","Crimson Cave","The_Crimson_Caveclik_thumb.jpg",130,86,32);thumbnails[5453322]=new thumbnail(5453322,"308195","Flight of the seabirds","flight_of_the_seabirds_1clik_thumb.jpg",130,93,32);thumbnails[5574179]=new thumbnail(5574179,"308195","Something dark","Something_darkclik_thumb.jpg",130,86,32);thumbnails[5574182]=new thumbnail(5574182,"308195","Golden sun rays","Golden_sunrays_thumb.jpg",130,86,32);thumbnails[5710991]=new thumbnail(5710991,"308195","Fractal twig abstract","fractal_twig_clik_thumb.jpg",130,86,32);thumbnails[6091185]=new thumbnail(6091185,"159642","Dittisham at dawn","Dittisham_dawn_clik_thumb.jpg",130,86,32);thumbnails[6092550]=new thumbnail(6092550,"159641","Male gorilla","_NLM0220gorilla_four_clik_thumb.jpg",130,86,32);thumbnails[6092554]=new thumbnail(6092554,"308195","Tiny dancer","Tiny_dancer_clik_thumb.jpg",130,86,32);thumbnails[6256318]=new thumbnail(6256318,"159641","Nutty Mouse","_NLM0064_Nutty_mouse_clik_thumb.jpg",130,94,32);thumbnails[6256336]=new thumbnail(6256336,"159640","Blue clematis flower ","_NLM0167_clematis_clik_thumb.jpg",130,86,32);thumbnails[6256349]=new thumbnail(6256349,"159640","Orange lily","_NLM0031_lily_three_basic_clik_thumb.jpg",130,86,32);thumbnails[6256371]=new thumbnail(6256371,"159640","Delicate rose","_NLM0038delicate_rose_clik_thumb.jpg",130,86,32);thumbnails[6256385]=new thumbnail(6256385,"159641","Red panda hiding","_NLM0024red_panda_hiding_clik_thumb.jpg",130,82,32);thumbnails[6256388]=new thumbnail(6256388,"159641","Wot you got?","_NLM0044two_orangs_clik_thumb.jpg",130,93,32);thumbnails[6256392]=new thumbnail(6256392,"159642","Reflecting masts","_NLM0163Reflecting_masts_clik_thumb.jpg",130,86,32);thumbnails[6256394]=new thumbnail(6256394,"159639","Lone heron","_NLM0088lone_heron_clik_thumb.jpg",130,86,32);thumbnails[6256395]=new thumbnail(6256395,"159641","Orangutan","_NLM0188Orang_three_clik_thumb.jpg",130,86,32);thumbnails[6256399]=new thumbnail(6256399,"159641","Cheetah","Cheetah_one_clik_thumb.jpg",130,87,32);thumbnails[6256401]=new thumbnail(6256401,"159641","Wolves","wolves_one_clik_thumb.jpg",130,87,32);thumbnails[6256423]=new thumbnail(6256423,"159641","Cheetah","_NLM0160cheetah_one_plus_clik_thumb.jpg",130,86,32);thumbnails[6256425]=new thumbnail(6256425,"159641","Tiger","_NLM0157tiger_one_clik_thumb.jpg",130,86,32);thumbnails[6256433]=new thumbnail(6256433,"159639","Whitethroat","whitethroat_clik_thumb.jpg",130,95,32);thumbnails[6396063]=new thumbnail(6396063,"308195","Abstract Zebra","fractal_abstact_zebraclik_thumb.jpg",111,130,32);thumbnails[3324658]=new thumbnail(3324658,"159393","","DSC_0082mouseclikpic_thumb.jpg",130,107,32);thumbnails[3324662]=new thumbnail(3324662,"159393","","DSC_0083otterclikpic_thumb.jpg",130,102,32);thumbnails[3324663]=new thumbnail(3324663,"159393","","DSC_0085lakeclikpic_thumb.jpg",130,106,32);thumbnails[3324664]=new thumbnail(3324664,"159393","","DSC_0086robinclikpic_thumb.jpg",130,104,32);thumbnails[3324665]=new thumbnail(3324665,"159393","","DSC_0089churchclikpic_thumb.jpg",130,107,32);thumbnails[4230885]=new thumbnail(4230885,"159394","Sunset above the Dart valley","Sunset_panorama_over_the_DartClik_thumb.jpg",130,45,32);thumbnails[5266173]=new thumbnail(5266173,"159394","Mist over Blackmore Vale","blackmore_vale_8shot_panoramafinishedclik_thumb.jpg",130,21,32);var galleries=new Object();galleries[159639]=new gallery(159639,"6256433,6256394,5122830,4547390,4257239,4098056,3879610,3874206,3622381,3579120","Birds","gallery",[2487498,2487499,2487502,2487508,2487509,2487513,2487541,2864164,3508232,3517756,3579069,3579120,3622381,3874206,3879610,4098056,4257239,4547390,5122830,6256394,6256433]);galleries[159640]=new gallery(159640,"6256371,6256349,6256336,4857987,4857981,2495748,2495744,2495718,2495701,2491390","Flowers","gallery",[2487597,2491384,2491389,2491390,2495701,2495718,2495744,2495748,4857981,4857987,6256336,6256349,6256371]);galleries[308195]=new gallery(308195,"6396063,6092554,5710991,5574182,5574179,5453322,5395013,5395011,5395007,5395005","Fractal photos","gallery",[5310836,5312920,5312957,5394989,5394995,5395000,5395005,5395007,5395011,5395013,5453322,5574179,5574182,5710991,6092554,6396063]);galleries[159642]=new gallery(159642,"6256392,6091185,5122811,5122806,2491399,2491395,2491391,2487612","Miscellaneous","gallery",[2487612,2491391,2491395,2491399,5122806,5122811,6091185,6256392]);galleries[159641]=new gallery(159641,"6256425,6256423,6256401,6256399,6256395,6256388,6256385,6256318,6092550,4999851","Wildlife","gallery",[2487601,2487603,2487605,2487606,2495649,3517746,3517755,3620936,4410809,4410816,4410824,4410828,4410835,4999845,4999851,6092550,6256318,6256385,6256388,6256395,6256399,6256401,6256423,6256425]);galleries[159393]=new gallery(159393,"3324665,3324664,3324663,3324662,3324658","Framed photos","gallery",[3324658,3324662,3324663,3324664,3324665]);galleries[159394]=new gallery(159394,"5266173,4230885","New attempts!","gallery",[4230885,5266173]);var imageSets=new Object();imageSets[1]="5312920";imageSets[3]="6396063,6256433,6256425,6256423,6256401,6256399,6256395,6256394,6256392,6256388,6256385,6256371,6256349,6256336,6256318,6092554,6092550,6091185,5710991,5574182,5574179,5453322,5395013,5395011,5395007,5395005,5395000,5394995,5394989,5312957,5312920,5310836,5266173,5122830,5122811,5122806,4999851,4999845,4857987,4857981,4547390,4410835,4410828,4410824,4410816,4410809,4257239,4230885,4098056,3879610";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/fisher/images";break}switch(a){case 1:b="http://www1.clikpic.com/fisher/images";break}switch(a){case 2:b="http://admin.clikpic.com/fisher/images";break}switch(a){case 24:b="http://tpc15/clikpic/fisher/images";break}switch(a){case 4:b="http://www.clikchurch.com/fisher/images";break}switch(a){case 5:b="http://www2.clikpic.com/fisher/images";break}switch(a){case 22:b="http://tpc5/clikpic/fisher/images";break}switch(a){case 23:b="http://tpc10/clikpic/fisher/images";break}switch(a){case 25:b="http://tpc16/clikpic/fisher/images";break}switch(a){case 15:b="http://www3.clikpic.com/fisher/images";break}switch(a){case 18:b="http://www4.clikpic.com/fisher/images";break}switch(a){case 19:b="http://www5.clikpic.com/fisher/images";break}switch(a){case 31:b="http://www7.clikpic.com/fisher/images";break}switch(a){case 32:b="http://admin2.clikpic.com/fisher/images";break}switch(a){case 33:b="http://www8.clikpic.com/fisher/images";break}switch(a){case 34:b="http://www9.clikpic.com/fisher/images";break}switch(a){case 35:b="http://admin3.clikpic.com/fisher/images";break}switch(a){case 37:b="http://admin4.clikpic.com/fisher/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="Trevor Ashford 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;resizePhotoInfo({centre:true});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="trevor@tda1.wanadoo.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="trevor@tda1.wanadoo.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(b,a){imageID=randomListVal(galleries[b].featured_images);if(imageID!=0){a.src=thumbnails[imageID].src;a.width=thumbnails[imageID].width;a.height=thumbnails[imageID].height}}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+'")'})}}};