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[6335633]=new thumbnail(6335633,"218378","","DSCF2146_thumb.JPG",130,210,1);thumbnails[3571769]=new thumbnail(3571769,"218378",'Look out for the "Pointer" shaped signs and cheerful yellow colours of the gallery!',"DSCF0918_thumb.jpg",130,165,1);thumbnails[3571858]=new thumbnail(3571858,"218378","Posy Single Stem Earrings, Silver by Anna K Baldwin.","Posy_single_stem_earrings_sml_pic_copy_thumb.jpg",130,97,1);thumbnails[3571965]=new thumbnail(3571965,"218378","Lion and Bee, Acrylic on Canvas by Lilapod.","lion_and_bee_copy1_thumb.jpg",130,129,1);thumbnails[3571970]=new thumbnail(3571970,"218378","Elephant and Bee, Acrylic on Canvas by Lilapod.","elephant_and_bee_copy_thumb.jpg",130,130,1);thumbnails[3571972]=new thumbnail(3571972,"218378","Honey Bee, Acrylic on Canvas by Lilapod.","honey_bee_copy_thumb.jpg",130,130,1);thumbnails[4648560]=new thumbnail(4648560,"218378","Lucianna Gallucci Ceramics","Lucianna_Gallucci_3_copy_thumb.jpg",130,98,1);thumbnails[4648566]=new thumbnail(4648566,"218378","Lucianna Galluci Ceramics","Lucianna_Gallucci_2_copy_thumb.jpg",130,173,1);thumbnails[4648563]=new thumbnail(4648563,"218378","Lucianna Gallucci Ceramics","1214338454_lucigallucci6_copy_thumb.jpg",130,181,1);thumbnails[5214371]=new thumbnail(5214371,"218378","Jill Green Screen-Printed Soft Leather Purses","DSCF1468_copy_thumb.jpg",130,103,1);thumbnails[4648614]=new thumbnail(4648614,"218378","Jill Green Screen-Printed Blackbird Card","Jill_blackbird_copy_thumb.jpg",130,184,1);thumbnails[4648619]=new thumbnail(4648619,"218378","Jill Green Screen-Printed Bluebells Card","Jill_bluebells_copy_thumb.jpg",130,130,1);thumbnails[4648628]=new thumbnail(4648628,"218378","Chris Townsend, Wychwood Tree","047_copy_thumb.jpg",130,128,1);thumbnails[4648641]=new thumbnail(4648641,"218378","Chris Townsend, Wychwood Branch","wychwood_branch_copy_thumb.jpg",130,64,1);thumbnails[4648669]=new thumbnail(4648669,"218378","Kirsty Shaw Butterfly Light","thumb_model_1103_-butterfly_thumb.jpg",130,153,1);thumbnails[4648672]=new thumbnail(4648672,"218378","Kirsty Shaw, LED Nightlight","thumb_12_White_Spotty_LED_feature_lamp_thumb.jpg",130,203,1);thumbnails[4648685]=new thumbnail(4648685,"218378","Kirsty Shaw Butterfly Light","thumb_1_Model_1120_-_Butterfly_light_thumb.jpg",130,176,1);thumbnails[4648867]=new thumbnail(4648867,"218378","Whistling Cowgirl Retropets","Cowgirl_toys_thumb.jpg",130,130,1);thumbnails[4648871]=new thumbnail(4648871,"218378","Whistling Cowgirl Lavender Puppies","cowgirl_dogs_thumb.jpg",130,130,1);thumbnails[4648911]=new thumbnail(4648911,"218378","Whistling Cowgirl Lavender Bird","Cowgirl_bird_thumb.jpg",130,130,1);thumbnails[5214413]=new thumbnail(5214413,"218378","Karen Tinkler screenprint","DSCF1806_thumb.JPG",130,149,1);thumbnails[5214427]=new thumbnail(5214427,"218378","Karen Tinkler screenprint with porcelain detail","bulb_thumb.JPG",130,130,1);thumbnails[5214435]=new thumbnail(5214435,"218378","Karen Tinkler screenprint with porcelain detail","day_thumb.JPG",130,131,1);thumbnails[5214984]=new thumbnail(5214984,"218378","Ben Bird wall mirror by TitiMadam.","ben_thumb.jpg",130,86,1);thumbnails[5214994]=new thumbnail(5214994,"218378","Three dimensional pop-out and assemble wooden cards by TitiMadam.","card_-_tree_1_thumb.jpg",130,83,1);thumbnails[5215007]=new thumbnail(5215007,"218378","Animal themed pendants by TitiMadam.","pendents_thumb.jpg",130,86,1);thumbnails[5765396]=new thumbnail(5765396,"218378","Jayne Lucas Ceramics","5_vessels_copy_thumb.jpg",130,99,1);thumbnails[5765398]=new thumbnail(5765398,"218378","Jayne Lucas, Large Flat Dish.","large_flat_dish_copy_thumb.jpg",130,98,1);thumbnails[5765402]=new thumbnail(5765402,"218378","Jayne Lucas, Tiny Dishes  £15 each.","tiny_dish_copy_thumb.jpg",130,98,1);thumbnails[1686919]=new thumbnail(1686919,"61357","Medium Catfish Resin & Enamel Paint in Beige and Black with Flowers,  £165, 34 by 31 by 7.5cm.  This item is sold.  (SOLD).        <br>\r\n","10_Catfish_small_-_Copy1_thumb.jpg",130,129,1);thumbnails[3571241]=new thumbnail(3571241,"61357","Commission for 387 Vets outside the practice with the proprietor.","DSCF0912_thumb.JPG",130,198,1);thumbnails[3571301]=new thumbnail(3571301,"61357",'Commission for "387 Vets" in Staffordshire.',"387_Pointer_with_base__-_Copy_thumb.JPG",130,101,1);thumbnails[3571447]=new thumbnail(3571447,"61357","Commission for Marion's Antiques outside the shop in Windsor.","flower_gundog_047_thumb.jpg",130,173,1);thumbnails[3571456]=new thumbnail(3571456,"61357","Commission for Marion's Antiques.","flower_gundog_035_thumb.jpg",130,98,1);thumbnails[5650483]=new thumbnail(5650483,"61357","Small Catfish Sculpture with Jute Bag ","Catfish_Mini-Sculpture_with_Jute_Bag_-_Copy12_thumb.JPG",130,160,1);thumbnails[5650487]=new thumbnail(5650487,"61357","Small Danger Mouse Sculpture with Jute Bag.","Danger_Mouse_Mini-Sculpture_with_Jute_Bag_-_Copy1_thumb.JPG",130,128,1);thumbnails[5650499]=new thumbnail(5650499,"61357","Small Dog 'n' Bone Sculpture with Jute Bag.","Dog_n_Bone_Mini-Sculpture_with_Jute_Bag_-_Copy1_thumb.JPG",130,128,1);thumbnails[5650507]=new thumbnail(5650507,"61357","Small Gundog Sculpture with Jute Bag.","Gundog_Mini-Sculpture_with_Jute_Bag_-_Copy1_thumb.JPG",130,128,1);thumbnails[5650512]=new thumbnail(5650512,"61357","Small House Mouse Sculpture with Jute Bag.","House_Mouse_Mini_Sculpture_with_Jute_Bag_-_Copy12_thumb.JPG",130,144,1);thumbnails[5650519]=new thumbnail(5650519,"61357","Small Bow Wow! Sculpture with Jute Bag.","Bow-Wow_Mini_Sculpture_with_Jute_Bag_-_Copy12_thumb.JPG",130,140,1);thumbnails[5650536]=new thumbnail(5650536,"61357","Small Love Bird Sculpture with LED lights.  To order.  This sculpture comes with a Jute bag.  £36.","Love_Bird_with_LED_Lights_-_Copy1_thumb.JPG",130,111,1);thumbnails[5650544]=new thumbnail(5650544,"61357","Small Sp-Arrow Sculpture with Jute Bag.","Sp-Arrow_Mini-Sculpture_with_Jute_Bag_-_Copy1_thumb.JPG",130,127,1);thumbnails[5748286]=new thumbnail(5748286,"61357","Large Gundog Sculpture Resin & Enamel Paint 48 by 71 by 11.5 cm £350","Gundog_Flower_-_Copy1234_thumb.jpg",130,93,1);thumbnails[1268891]=new thumbnail(1268891,"61357","Rocking Horse Resin & Enamel Paint in Blue with Flowers, 63 by 80 by 11.5cm £550.  (SOLD).","Rocking_horse_carnival_-_Copy1_thumb.jpg",130,112,1);thumbnails[1268890]=new thumbnail(1268890,"61357","Cool Cat Large Sculpture Resin & Iron 46 by 76 by 11.5cm £300.  This item is permanently exhibited at Careg Dhu Public Garden, St. Mary's, Isles of Scilly, Cornwall.","Cool_CatRust_by_pond_-_Copy12_thumb.jpg",130,95,1);thumbnails[1879554]=new thumbnail(1879554,"61357","Medium Llama Lamp Resin & Enamel Paint 28 by 31 by 7.5cm £95.","204_-_Copy12_thumb.JPG",130,139,1);thumbnails[1686879]=new thumbnail(1686879,"61357","Rocking Horse Large Sculpture Resin & Enamel Paint in Black and Beige, 63 by 80 by 11.5cm. (SOLD). £550.","7Rocking_Horse_large_-_Copy12_thumb.jpg",130,167,1);thumbnails[1891199]=new thumbnail(1891199,"61357","Pointer Large Sculpture Resin & Enamel Paint in White with Spots 57 by 75 by 11.5cm NFS.  ","Pointer_Resin__Enamel_2_57_x_75_x_115cm_-_Copy12_thumb.jpg",130,98,1);thumbnails[3235849]=new thumbnail(3235849,"43674","Heathland, Oil on Canvas, 76cm square. SOLD.","Heathland 90cm square _thumb.JPG",130,132,1);thumbnails[3562612]=new thumbnail(3562612,"43674","Meadow, Oil on Canvas, 76cm square.  SOLD.","Meadow_295_thumb.JPG",130,130,1);thumbnails[3562650]=new thumbnail(3562650,"43674","Lagoon, Oil on Canvas, 92 x 61cm.  £295.","Lagoon_295_thumb.JPG",130,195,1);thumbnails[5075004]=new thumbnail(5075004,"43674","Meadow II.  Acrylic on Canvas.  76cm square.","Meadow_II_thumb.JPG",130,132,1);thumbnails[5075012]=new thumbnail(5075012,"43674","Woodland.  Acrylic on Canvas.  76cm square.","Woodland_76cm_square_thumb.JPG",130,131,1);thumbnails[566494]=new thumbnail(566494,"43545","Tania drawing strolling caricatures.","Tania strolling_thumb.jpg",130,98,1);thumbnails[566520]=new thumbnail(566520,"43545","An on-the-spot caricature.","Tania drawing_thumb.JPG",130,95,1);thumbnails[789752]=new thumbnail(789752,"43545","Star Trek","Star Trek (Pencil) 009_thumb.jpg",130,98,1);thumbnails[1686730]=new thumbnail(1686730,"43545","Tania's latest victims show off their on-the-spot caricatures.","IMG_0095_thumb.JPG",130,137,1);thumbnails[5075181]=new thumbnail(5075181,"43545","Mine's a Babycham!","DSCF1281_thumb.JPG",130,167,1);thumbnails[5075342]=new thumbnail(5075342,"43545","John F. Kennedy in the driving seat. (Bus Window Commission).","John_F_Kennedy__thumb.JPG",130,125,1);thumbnails[5075358]=new thumbnail(5075358,"43545","Mary Quant Vogueing (Bus Window Commission).","Mary_Quant_thumb.JPG",130,44,1);thumbnails[5075488]=new thumbnail(5075488,"43545","Kick Boxing Caricature.","kick_boxing_caricature_thumb.JPG",130,179,1);thumbnails[5075627]=new thumbnail(5075627,"43545","RHS Tatton Park Commission.","Tatton_Park_Caricature__thumb.JPG",130,98,1);thumbnails[565101]=new thumbnail(565101,"43545","Dougie (Ink on Paper)","Dougie 1 (ink)_thumb.jpg",130,183,1);thumbnails[565080]=new thumbnail(565080,"43545","The Wedding of Charles and Gorilla (Ink on Paper)","Charles & Gorilla (scan)_thumb.JPG",130,95,1);thumbnails[565089]=new thumbnail(565089,"43545","Ant and Dec (Ink on Paper)","Ant & Dec_thumb.JPG",130,172,1);thumbnails[565096]=new thumbnail(565096,"43545","De Vere Whites Calender Cover (Ink and Watercolour on Paper)","De Vere Whites Calendar Cover Colour_thumb.jpg",130,194,1);thumbnails[565112]=new thumbnail(565112,"43545","Sarah (Ink and Watercolour on paper)","Sarah_thumb.jpg",130,181,1);thumbnails[565115]=new thumbnail(565115,"43545","Wedding Caricature (Ink on Paper)","wedding caricature (ink)_thumb.jpg",130,186,1);thumbnails[565122]=new thumbnail(565122,"43545","The Vice Girls (Detail - Ink on Paper)","The Vice Girls (scan)_thumb.JPG",130,95,1);var galleries=new Object();galleries[218378]=new gallery(218378,"3571769","Bridgnorth Gallery and Artists","gallery",[6335633,3571769,3571858,3571965,3571970,3571972,4648560,4648566,4648563,5214371,4648614,4648619,4648628,4648641,4648669,4648672,4648685,4648867,4648871,4648911,5214413,5214427,5214435,5214984,5214994,5215007,5765396,5765398,5765402]);galleries[61357]=new gallery(61357,"3571301,1686919","Sculpture Gallery","gallery",[1686919,3571241,3571301,3571447,3571456,5650483,5650487,5650499,5650507,5650512,5650519,5650536,5650544,5748286,1268891,1268890,1879554,1686879,1891199]);galleries[43674]=new gallery(43674,"5075012,5075004,3562650,3562612,3235849","Painting Gallery","gallery",[3235849,3562612,3562650,5075004,5075012]);galleries[43545]=new gallery(43545,"565115,565089","Caricature Portfolio","gallery",[566494,566520,789752,1686730,5075181,5075342,5075358,5075488,5075627,565101,565080,565089,565096,565112,565115,565122]);var imageSets=new Object();imageSets[1]="5748286,1891199,1879554,1686879,1268891,1268890";imageSets[2]="3571769,3571301,1686919,565115,565089";imageSets[3]="6335633,5765402,5765398,5765396,5748286,5650544,5650536,5650519,5650512,5650507,5650499,5650487,5650483,5215007,5214994,5214984,5214435,5214427,5214413,5214371,5075627,5075488,5075358,5075342,5075181,5075012,5075004,4648911,4648871,4648867,4648685,4648672,4648669,4648641,4648628,4648619,4648614,4648566,4648563,4648560,3571972,3571970,3571965,3571858,3571769,3571456,3571447,3571301,3571241,3562650";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/gwendoline/images";break}switch(a){case 1:b="http://www1.clikpic.com/gwendoline/images";break}switch(a){case 2:b="http://admin.clikpic.com/gwendoline/images";break}switch(a){case 24:b="http://tpc15/clikpic/gwendoline/images";break}switch(a){case 4:b="http://www.clikchurch.com/gwendoline/images";break}switch(a){case 5:b="http://www2.clikpic.com/gwendoline/images";break}switch(a){case 22:b="http://tpc5/clikpic/gwendoline/images";break}switch(a){case 23:b="http://tpc10/clikpic/gwendoline/images";break}switch(a){case 25:b="http://tpc16/clikpic/gwendoline/images";break}switch(a){case 15:b="http://www3.clikpic.com/gwendoline/images";break}switch(a){case 18:b="http://www4.clikpic.com/gwendoline/images";break}switch(a){case 19:b="http://www5.clikpic.com/gwendoline/images";break}switch(a){case 31:b="http://www7.clikpic.com/gwendoline/images";break}switch(a){case 32:b="http://admin2.clikpic.com/gwendoline/images";break}switch(a){case 33:b="http://www8.clikpic.com/gwendoline/images";break}switch(a){case 34:b="http://www9.clikpic.com/gwendoline/images";break}switch(a){case 35:b="http://admin3.clikpic.com/gwendoline/images";break}switch(a){case 37:b="http://admin4.clikpic.com/gwendoline/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="Tania Holland Gallery : "+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();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="updateCartValue(document.forms.paymentForm,this.form.payment_options_id.options[this.form.payment_options_id.options.selectedIndex].value); if(divShowing(\'paymentConfirm\')){fadeOut(\'paymentConfirm\', 3)};">';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">';b=b+'	<input type="hidden" name="item_option" value="'+a+'">';b=b+'	<input type="hidden" name="site" value="GWENDOLINE">';b=b+'	<input type="hidden" name="item_number" value="'+c.id+'">';b=b+'	<input type="hidden" name="quantity" value="1">';b=b+'	<input value="Add to cart" id="paymentAddButton" class="button" onmouseover="this.className=\'buttonHi\';" onmouseout="this.className=\'button\';" type="Button">';b=b+'	<input value="View cart" id="paymentViewButton" class="button" onmouseover="this.className=\'buttonHi\';" onmouseout="this.className=\'button\';" type="Button" onclick="javascript:window.location=\'cart.html\'">';b=b+"</form>";b=b+'<div class="clearing">&nbsp;</div>';b=b+'<div id="confirmContainer">';b=b+'<div id="paymentConfirm">Item added to cart</div>';b=b+"</div>";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 e=$("img#gallery"+c);e.parents(".thumbWrap").width(b.width);var a=e.siblings("h3").size()==1?e.siblings("h3"):e.parent(".thumbWrap").siblings("h3");var f=parseInt(a.css("padding-left"))+parseInt(a.css("padding-right"));var d=parseInt(a.css("border-left-width"))+parseInt(a.css("border-right-width"));a.width(e.outerWidth(true)-f-d)}}}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+'")'})}}};