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[1317850]=new thumbnail(1317850,"118650","Hi I am Heather","Image 4 web_thumb.jpg",130,124,1);thumbnails[1765725]=new thumbnail(1765725,"118650","","IMG_1441_thumb.JPG",130,173,1);thumbnails[1765803]=new thumbnail(1765803,"118650","Himalayan Ranges","DSCN0616_thumb.JPG",130,173,1);thumbnails[1765810]=new thumbnail(1765810,"118650","Himalayan Ranges","DSCN0684_thumb.JPG",130,173,1);thumbnails[1765817]=new thumbnail(1765817,"118650","Indus River, Ladakh, India","DSCN0712_thumb.JPG",130,173,1);thumbnails[1765822]=new thumbnail(1765822,"118650","View from my room, Ley, Ladakh","Moon light in Ley_thumb.JPG",130,173,1);thumbnails[1776374]=new thumbnail(1776374,"118650","Angkor Wat, Cambodia","Monks_thumb.JPG",130,173,1);thumbnails[1797033]=new thumbnail(1797033,"118650","Uluru, Australia","test1_1_thumb.jpg",130,173,1);thumbnails[1797035]=new thumbnail(1797035,"118650","Uluru, Australia","Resize Wizard-1_thumb.jpg",130,173,1);thumbnails[1797038]=new thumbnail(1797038,"118650","Bondi Beach, Australia","Bondi Beauty2_thumb.jpg",130,173,1);thumbnails[5417712]=new thumbnail(5417712,"118650","Machu Picchu Peru","Captured_2009-12-17_00015_thumb.JPG",130,173,1);thumbnails[2220474]=new thumbnail(2220474,"118650","Sokha Beach, Cambodia","Ocean Blue_thumb.JPG",130,173,1);thumbnails[2045475]=new thumbnail(2045475,"118650","Sleeping Buddha,Wat Poh, Bangkok","Sleeping buddha_thumb.JPG",130,98,1);thumbnails[1797052]=new thumbnail(1797052,"118650","Pang-gong Lake, Ladakh","Panggong21_thumb.JPG",130,98,1);thumbnails[2638379]=new thumbnail(2638379,"20891","Faraway (sold)","DSCN1756_thumb.JPG",130,136,1);thumbnails[2974349]=new thumbnail(2974349,"20891","God's Creation (Sold)","1_thumb.JPG",130,130,1);thumbnails[1961001]=new thumbnail(1961001,"20891","Blue Eclipse","Blue Eclipse_thumb.JPG",130,128,1);thumbnails[346850]=new thumbnail(346850,"20891","Surrender","Surrender_thumb.JPG",130,130,1);thumbnails[2133550]=new thumbnail(2133550,"20891","Paradise Sunset (sold)","DSCN1585_thumb.JPG",130,129,1);thumbnails[337725]=new thumbnail(337725,"20891","Solitary Shore (SOLD)","Solitary Shore_thumb.JPG",130,130,1);thumbnails[2633208]=new thumbnail(2633208,"20891","Moonlight Glow 1 (sold)","DSCN17571_thumb.JPG",130,129,1);thumbnails[2133553]=new thumbnail(2133553,"20891","Evening Glow","DSCN1588_thumb.JPG",130,130,1);thumbnails[346843]=new thumbnail(346843,"20891","Through the Calm","Find the Calm_thumb.JPG",130,124,1);thumbnails[1961024]=new thumbnail(1961024,"20891","Rocky Shore","Web1_thumb.JPG",130,128,1);thumbnails[1797016]=new thumbnail(1797016,"20891","Summer Breeze (sold)","DSCN0979_thumb.JPG",130,129,1);thumbnails[2030140]=new thumbnail(2030140,"20891","On the edge (sold)","DSCN1534_thumb.JPG",130,131,1);thumbnails[1797011]=new thumbnail(1797011,"20891","Brecon Sunset","DSCN0985_thumb.JPG",130,127,1);thumbnails[2030152]=new thumbnail(2030152,"20891","Silver Sands (Sold)","Rocky Shore1_thumb.JPG",130,130,1);thumbnails[1961016]=new thumbnail(1961016,"20891","Cool Ocean  (Triptych) (Sold)","DSCN1441_thumb.JPG",130,130,1);thumbnails[2070258]=new thumbnail(2070258,"20891","Sunset Waves","DSCN1559_thumb.JPG",130,130,1);thumbnails[2638318]=new thumbnail(2638318,"20891","Breaking Waves (Sold)","DSCN1765_thumb.JPG",130,127,1);thumbnails[1797010]=new thumbnail(1797010,"20891","Coral Splash (sold)","IMG_1456_thumb.JPG",130,130,1);thumbnails[2974355]=new thumbnail(2974355,"20891","Special Place (Sold)","4_thumb.JPG",130,128,1);thumbnails[2277968]=new thumbnail(2277968,"20891","Fresh Water Bay (Sold)","Web11_thumb.JPG",130,129,1);thumbnails[2633199]=new thumbnail(2633199,"20891","Still","Still_thumb.JPG",130,129,1);thumbnails[2974351]=new thumbnail(2974351,"20891","  Purple Haze (Sold)","3_thumb.JPG",130,128,1);thumbnails[2974350]=new thumbnail(2974350,"20891","Golden Sands (Sold)","2_thumb.JPG",130,131,1);thumbnails[2974360]=new thumbnail(2974360,"20891","Quiet Storm (Sold)","8_thumb.JPG",130,130,1);thumbnails[242132]=new thumbnail(242132,"20891","Moonlight calm","IMG_0863_thumb.JPG",130,99,1);thumbnails[3401095]=new thumbnail(3401095,"20891","Storm Shadows","DSCN1880_thumb.JPG",130,73,1);thumbnails[4960451]=new thumbnail(4960451,"20882","Mountain Magic","Mountain_Magic_thumb.JPG",130,111,1);thumbnails[693759]=new thumbnail(693759,"20882","Spring Meadow (Sold)","Summer Meadow_thumb.JPG",130,172,1);thumbnails[1961008]=new thumbnail(1961008,"20882","Organic Earth (Sold)","DSCN1432_thumb.JPG",130,133,1);thumbnails[531800]=new thumbnail(531800,"20882","Autumn Meadow  (SOLD)","Owens_thumb.JPG",130,130,1);thumbnails[512565]=new thumbnail(512565,"20882","Autumns Path (SOLD)","IMG_1240_thumb.JPG",130,130,1);thumbnails[1961006]=new thumbnail(1961006,"20882","Desert Swirl","Desert Swirl_thumb.JPG",130,129,1);thumbnails[2633202]=new thumbnail(2633202,"20882","Enchanted Forest (Sold)","Enchanted Forest_thumb.JPG",130,129,1);thumbnails[2070287]=new thumbnail(2070287,"20882","Last Light","DSCN1565_thumb.JPG",130,130,1);thumbnails[1797017]=new thumbnail(1797017,"20882","Pang Gong Lake1","Lake1_thumb.JPG",130,98,1);thumbnails[1797018]=new thumbnail(1797018,"20882","Pang Gong Lake2","Lake2_thumb.JPG",130,96,1);thumbnails[4771209]=new thumbnail(4771209,"20882","Mountain Breeze","DSCN2123_thumb.JPG",130,107,1);thumbnails[2282055]=new thumbnail(2282055,"20882","Lavender Fields","DSCN1641_thumb.JPG",130,49,1);thumbnails[702312]=new thumbnail(702312,"20888","New Horizons","New Horizon_thumb.JPG",130,173,1);thumbnails[242130]=new thumbnail(242130,"20888","The Crossing","IMG_0860_thumb.JPG",130,171,1);thumbnails[1320204]=new thumbnail(1320204,"20888","What the eyes can see","Test 2_thumb.JPG",130,174,1);thumbnails[236789]=new thumbnail(236789,"20888","Shadow Dance","Shadow Dance 20x28ins_thumb.jpg",130,183,1);thumbnails[346842]=new thumbnail(346842,"20888","The Bigger Picture","The bigger picture_thumb.JPG",130,130,1);thumbnails[231940]=new thumbnail(231940,"20888","Oblivion ","Oblivion_thumb.JPG",130,131,1);thumbnails[512574]=new thumbnail(512574,"20888","Earth's Crust (Sold)","IMG_1155_thumb.JPG",130,129,1);thumbnails[512577]=new thumbnail(512577,"20888","Harmony (Sold)","IMG_1157_thumb.JPG",130,129,1);thumbnails[1961011]=new thumbnail(1961011,"20888","Midnights Veil","Midnight_thumb.JPG",130,133,1);thumbnails[236770]=new thumbnail(236770,"20888","The Path (Triptych)(SOLD)","The Path 24x24 £200_thumb.jpg",130,133,1);thumbnails[4771155]=new thumbnail(4771155,"20888","Another Layer","DSCN2125_thumb.JPG",130,128,1);thumbnails[2070330]=new thumbnail(2070330,"20888","Entwined (Diptych) ","DSCN1563_thumb.JPG",130,130,1);thumbnails[702315]=new thumbnail(702315,"20888","Silver Lining","Silver Lining_thumb.JPG",130,119,1);thumbnails[537668]=new thumbnail(537668,"41820","Out of the Shadows","artwork trans1 010_thumb.jpg",130,172,1);thumbnails[537760]=new thumbnail(537760,"41820","Amethyst Crown (Donated to the Institute of Cancer Research Radiotherapy Dept)","IMG_1251_thumb.JPG",130,82,1);thumbnails[1320203]=new thumbnail(1320203,"41820","Shattered Earth","Shattered Earth_thumb.JPG",130,130,1);thumbnails[562294]=new thumbnail(562294,"41820","Forever Sunset (SOLD)","IMG_1321_thumb.JPG",130,97,1);thumbnails[231909]=new thumbnail(231909,"41820","From Heaven to Earth","From Earth to Heaven 40x50ins 1_thumb.JPG",130,98,1);thumbnails[1318623]=new thumbnail(1318623,"41820","Middle Earth","Middle Earth 21_thumb.jpg",130,83,1);thumbnails[702307]=new thumbnail(702307,"41820","Chiang Mai Sunset 3","Chiang Mai Sunset_thumb.JPG",130,111,1);thumbnails[2074174]=new thumbnail(2074174,"154668","Ocean's Serenade","DSCN1568_thumb.JPG",130,171,1);thumbnails[2277969]=new thumbnail(2277969,"154668","Chaing Mai Sunset (2)","Web21_thumb.JPG",130,100,1);thumbnails[5417437]=new thumbnail(5417437,"154668","","Dr_Rapleys_Peice1_thumb.jpg",130,155,1);thumbnails[236898]=new thumbnail(236898,"154668","","Painting_2barb1_thumb.jpg",130,210,1);thumbnails[236899]=new thumbnail(236899,"154668","Evening Lake","Painting1Barb_thumb.jpg",130,211,1);thumbnails[232279]=new thumbnail(232279,"154668","Vortex Dream","Vortex dream 40x50in Oil on Canvas_thumb.JPG",130,98,1);thumbnails[237622]=new thumbnail(237622,"154668","Essence of light","IMG_0760_thumb.JPG",130,98,1);thumbnails[2400002]=new thumbnail(2400002,"20890","Mother of Creation","Nature_thumb.JPG",130,135,1);thumbnails[4960446]=new thumbnail(4960446,"20890","Circles of Life","Circles_of_Life1_thumb.JPG",130,132,1);thumbnails[2074171]=new thumbnail(2074171,"20890","To be","DSCN1574_thumb.JPG",130,171,1);thumbnails[4960176]=new thumbnail(4960176,"20890","Free to Fly","Free_to_Fly_thumb.JPG",130,132,1);thumbnails[2070221]=new thumbnail(2070221,"20890","Elegance (Sold)","DSCN1557_thumb.JPG",130,174,1);thumbnails[2061791]=new thumbnail(2061791,"20890","Defiance","DSCN1544_thumb.JPG",130,174,1);thumbnails[2061789]=new thumbnail(2061789,"20890","The Nomad (Sold)","Nomad_thumb.JPG",130,176,1);thumbnails[242127]=new thumbnail(242127,"20890","Blessed","IMG_0858_thumb.JPG",130,173,1);thumbnails[693750]=new thumbnail(693750,"20890","Healing Angel (Not available, auction at Christies for Cancer Research)","Healing Angel_thumb.JPG",130,118,1);thumbnails[232264]=new thumbnail(232264,"20890","Lost","Lost 16x20in Acrylic on paper ( framed)£250_thumb.JPG",130,131,1);thumbnails[512585]=new thumbnail(512585,"20890","Through the Haze (Sold)","IMG_1196_thumb.JPG",130,102,1);thumbnails[433266]=new thumbnail(433266,"20890","Little Sister (Sold)","IMG_1176_thumb.JPG",130,113,1);thumbnails[278098]=new thumbnail(278098,"20890","Silent Presence ","5thelement_thumb.JPG",130,97,1);thumbnails[3401084]=new thumbnail(3401084,"20890","Desire (sold)","DSCN1884_thumb.JPG",130,173,1);thumbnails[512579]=new thumbnail(512579,"20890","The Wanderer (SOLD)","IMG_1194_thumb.JPG",130,103,1);thumbnails[346854]=new thumbnail(346854,"20890","New Dawn","New dawn_thumb.JPG",130,98,1);thumbnails[3392912]=new thumbnail(3392912,"20890","The Kiss (Sold)","DSCN1872_thumb.JPG",130,131,1);var galleries=new Object();galleries[118650]=new gallery(118650,"1317850","My Inspiration","gallery",[1317850,1765725,1765803,1765810,1765817,1765822,1776374,1797033,1797035,1797038,5417712,2220474,2045475,1797052]);galleries[207702]=new gallery(207702,"","New work for 2010 coming soon!","gallery",[]);galleries[20891]=new gallery(20891,"3401095,2974360,2974355,2974351,2974350,2974349,2638379,2638318,2633208,2633199","Seascapes","gallery",[2638379,2974349,1961001,346850,2133550,337725,2633208,2133553,346843,1961024,1797016,2030140,1797011,2030152,1961016,2070258,2638318,1797010,2974355,2277968,2633199,2974351,2974350,2974360,242132,3401095]);galleries[20882]=new gallery(20882,"4960451,4771209,2633202,2282055,2070287,1961008,1961006,1797018,1797017,693759","Landscapes ","gallery",[4960451,693759,1961008,531800,512565,1961006,2633202,2070287,1797017,1797018,4771209,2282055]);galleries[20888]=new gallery(20888,"4771155,2070330,1961011,1320204,702315,702312,512577,512574,346842,242130","Abstract ","gallery",[702312,242130,1320204,236789,346842,231940,512574,512577,1961011,236770,4771155,2070330,702315]);galleries[41820]=new gallery(41820,"1320203,1318623,702307,562294,537760,537668,231909","Larger Canvases","gallery",[537668,537760,1320203,562294,231909,1318623,702307]);galleries[154668]=new gallery(154668,"5417437,2277969,2074174,237622,236899,236898,232279","Commissions","gallery",[2074174,2277969,5417437,236898,236899,232279,237622]);galleries[20890]=new gallery(20890,"4960446,4960176,3401084,3392912,2400002,2074171,2070221,2061791,2061789,693750","Figurative ","gallery",[2400002,4960446,2074171,4960176,2070221,2061791,2061789,242127,693750,232264,512585,433266,278098,3401084,512579,346854,3392912]);var imageSets=new Object();imageSets[1]="512579,231909";imageSets[2]="1317850";imageSets[3]="3401095";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/ellavell/images";break}switch(a){case 1:b="http://www1.clikpic.com/ellavell/images";break}switch(a){case 2:b="http://admin.clikpic.com/ellavell/images";break}switch(a){case 24:b="http://tpc15/clikpic/ellavell/images";break}switch(a){case 4:b="http://www.clikchurch.com/ellavell/images";break}switch(a){case 5:b="http://www2.clikpic.com/ellavell/images";break}switch(a){case 22:b="http://tpc5/clikpic/ellavell/images";break}switch(a){case 23:b="http://tpc10/clikpic/ellavell/images";break}switch(a){case 25:b="http://tpc16/clikpic/ellavell/images";break}switch(a){case 15:b="http://www3.clikpic.com/ellavell/images";break}switch(a){case 18:b="http://www4.clikpic.com/ellavell/images";break}switch(a){case 19:b="http://www5.clikpic.com/ellavell/images";break}switch(a){case 31:b="http://www7.clikpic.com/ellavell/images";break}switch(a){case 32:b="http://admin2.clikpic.com/ellavell/images";break}switch(a){case 33:b="http://www8.clikpic.com/ellavell/images";break}switch(a){case 34:b="http://www9.clikpic.com/ellavell/images";break}switch(a){case 35:b="http://admin3.clikpic.com/ellavell/images";break}switch(a){case 37:b="http://admin4.clikpic.com/ellavell/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="Heather McDonald: "+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+'")'})}}};