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[448182]=new thumbnail(448182,"","Handmade lampwork beads and lampworking frit blends, by Mary Parker. Made with love in Aberdeenshire.","flamingos_text_thumb.jpg",130,130,18);thumbnails[533945]=new thumbnail(533945,"","Bendy beads, Pink Opal ","pink_bendy_thumb.jpg",130,98,18);thumbnails[3482544]=new thumbnail(3482544,"","","My lampwork 20941_thumb.jpg",130,121,18);thumbnails[3482549]=new thumbnail(3482549,"","","My lampwork 17911_thumb.jpg",130,109,18);thumbnails[4999259]=new thumbnail(4999259,"36902","Caramel amphora SOLD","vessels_013_thumb.jpg",130,135,18);thumbnails[4999273]=new thumbnail(4999273,"36902","Passion amphora SOLD","vessels_018_thumb.jpg",130,146,18);thumbnails[4999278]=new thumbnail(4999278,"36902","Triton amphora SOLD","vessels_026_thumb.jpg",130,150,18);thumbnails[4999285]=new thumbnail(4999285,"36902","Pebble amphora SOLD","vessels_022_thumb.jpg",130,140,18);thumbnails[4999344]=new thumbnail(4999344,"36902","Turquoise amphora SOLD","vessels_025_thumb.jpg",130,146,18);thumbnails[3482505]=new thumbnail(3482505,"75812","Kildonan boro set","My lampwork 2178w_thumb.jpg",130,98,18);thumbnails[3482507]=new thumbnail(3482507,"75812","Blue Moon boro set 1","My lampwork 2170w_thumb.jpg",130,93,18);thumbnails[3482509]=new thumbnail(3482509,"75812","Blue Moon set 2","My lampwork 2174w_thumb.jpg",130,114,18);thumbnails[3482528]=new thumbnail(3482528,"75812","Fairy Lemonade set","My lampwork 2141_thumb.jpg",130,103,18);thumbnails[3482558]=new thumbnail(3482558,"75812","Ballantrae boro set SOLD","My lampwork 2152w_thumb.jpg",130,92,18);thumbnails[3482500]=new thumbnail(3482500,"35559","Tranquil set","My lampwork 2166w_thumb.jpg",130,95,18);thumbnails[3482531]=new thumbnail(3482531,"35559","Triton Jewels set","My lampwork 2154w_thumb.jpg",130,86,18);thumbnails[3482563]=new thumbnail(3482563,"35559","Chameleon Raku set","My lampwork 2180_thumb.jpg",130,109,18);thumbnails[3935874]=new thumbnail(3935874,"35559","Lemon Drops set","beads_056w_thumb.jpg",130,109,18);thumbnails[4514128]=new thumbnail(4514128,"35559","Twinkles set","mylampwork_040w_thumb.jpg",130,114,18);thumbnails[4818603]=new thumbnail(4818603,"35559","Triton Tapestry set","mylampwork_055_thumb.jpg",130,115,18);thumbnails[4818809]=new thumbnail(4818809,"35559","Periwinkle Tapestry set","mylampwork_063_thumb.jpg",130,98,18);thumbnails[2163159]=new thumbnail(2163159,"35601","Lily Pond focal","My lampwork 1511_thumb.jpg",130,121,18);thumbnails[2163197]=new thumbnail(2163197,"35601","Autumn storm","My lampwork 1516_thumb.jpg",130,112,18);thumbnails[2332278]=new thumbnail(2332278,"35601","Lollipop focal SOLD","My lampwork 1721_thumb.jpg",130,133,18);thumbnails[2744639]=new thumbnail(2744639,"35601","Violet Night Vessel","My lampwork 1936_thumb.jpg",130,141,18);thumbnails[3482513]=new thumbnail(3482513,"35601","Watercolour small focal","My lampwork 2127w_thumb.jpg",130,98,18);thumbnails[3482515]=new thumbnail(3482515,"35601","Moods small focal SOLD","My lampwork 2133w_thumb.jpg",130,120,18);thumbnails[3935688]=new thumbnail(3935688,"35601","Redwood focal SOLD","beads_030_thumb.jpg",130,113,18);thumbnails[3935883]=new thumbnail(3935883,"35601","Rainforest large focal","beads_045w_thumb.jpg",130,114,18);thumbnails[4513930]=new thumbnail(4513930,"35601","Wonderland large focal","mylampwork_033w_thumb.jpg",130,133,18);thumbnails[4514121]=new thumbnail(4514121,"35601","Smoky focal SOLD","mylampwork_028w_thumb.jpg",130,106,18);thumbnails[4554789]=new thumbnail(4554789,"35601","Imagine focal SOLD","ekho_004w_thumb.jpg",130,105,18);thumbnails[4554828]=new thumbnail(4554828,"35601","Serengeti focal SOLD","ekho_011w_thumb.jpg",130,97,18);thumbnails[4818674]=new thumbnail(4818674,"35601","Triton Tapestry focal SOLD","mylampwork_052_thumb.jpg",130,124,18);thumbnails[4818797]=new thumbnail(4818797,"35601","Chalcedony Sunset focal reserved","mylampwork_057_thumb.jpg",130,115,18);thumbnails[4818822]=new thumbnail(4818822,"35601","Periwinkle Tapestry large focal","mylampwork_061_thumb.jpg",130,118,18);thumbnails[4818875]=new thumbnail(4818875,"35601","Chalcedony Tapestry focal","mylampwork_025_thumb.jpg",130,107,18);thumbnails[2041313]=new thumbnail(2041313,"35601","Tapestry Large focal","My lampwork 1442_thumb.jpg",130,116,18);thumbnails[2483095]=new thumbnail(2483095,"35601","Cinnamon Swirl focal","My lampwork 1785_thumb.jpg",130,114,18);thumbnails[1464519]=new thumbnail(1464519,"101042","Lentil Sizes","My lampwork 875_thumb.jpg",130,98,18);thumbnails[1464529]=new thumbnail(1464529,"101042","Lentil","My lampwork 1247_thumb.jpg",130,116,18);thumbnails[1464530]=new thumbnail(1464530,"101042","Chunky Lentil","My lampwork 11901_thumb.jpg",130,98,18);thumbnails[1464533]=new thumbnail(1464533,"101042","Button or Spree","My lampwork 1239_thumb.jpg",130,123,18);thumbnails[1464535]=new thumbnail(1464535,"101042","Sleek Pillow or Nugget","My lampwork 1245_thumb.jpg",130,112,18);thumbnails[1464551]=new thumbnail(1464551,"101042","Curved Bendy Beads","My lampwork 9531_thumb.jpg",130,105,18);thumbnails[1492036]=new thumbnail(1492036,"101042","Large Button","My lampwork 1251_thumb.jpg",130,102,18);thumbnails[2214468]=new thumbnail(2214468,"101042","Large Pillow focals","My lampwork 1619_thumb.jpg",130,114,18);thumbnails[449350]=new thumbnail(449350,"23848","Chameleon Raku","chameleon_raku_thumb.jpg",130,98,18);thumbnails[449352]=new thumbnail(449352,"23848","Chocolate Beads","Chocolates_thumb.jpg",130,98,18);thumbnails[449354]=new thumbnail(449354,"23848","Copper Green Leaf","copper_green_leaf_thumb.jpg",130,98,18);thumbnails[449513]=new thumbnail(449513,"23848","Tapestry Focal","tapestry_focal_thumb.jpg",130,107,18);thumbnails[466600]=new thumbnail(466600,"23848","Raku Circus","raku_circus_2_thumb.jpg",130,98,18);thumbnails[494365]=new thumbnail(494365,"23848","Opal Mist","opal_mist_set_thumb.jpg",130,129,18);thumbnails[531807]=new thumbnail(531807,"23848","Bracelet with Kronos beads","bendy_bracelet_Kronos_thumb.jpg",130,93,18);thumbnails[546025]=new thumbnail(546025,"23848","Kronos Bendy Bracelet Beads","gaia 007_thumb.jpg",130,106,18);thumbnails[769334]=new thumbnail(769334,"23848","Chintz","My lampwork 326_thumb.jpg",130,100,18);thumbnails[828319]=new thumbnail(828319,"23848","Desert Pearls","My lampwork 560_thumb.jpg",130,103,18);thumbnails[828324]=new thumbnail(828324,"23848","Raku Tigers","My lampwork 557_thumb.jpg",130,93,18);thumbnails[1012900]=new thumbnail(1012900,"23848","Rothesay Seaweed","My lampwork 852_thumb.jpg",130,112,18);thumbnails[1017345]=new thumbnail(1017345,"23848","Carnelian Vessel SOLD","My lampwork 8521_thumb.jpg",130,156,18);thumbnails[1058132]=new thumbnail(1058132,"23848","Terra Sunset Harmony","My lampwork 913_thumb.jpg",130,98,18);thumbnails[1058137]=new thumbnail(1058137,"23848","Terra Symphony","My lampwork 909_thumb.jpg",130,111,18);thumbnails[1058143]=new thumbnail(1058143,"23848","Terra Sonata ","My lampwork 883_thumb.jpg",130,125,18);thumbnails[1067033]=new thumbnail(1067033,"23848","Cairngorms","My lampwork 926_thumb.jpg",130,125,18);thumbnails[1068079]=new thumbnail(1068079,"23848","Arran Moss","My lampwork 9621_thumb.jpg",130,114,18);thumbnails[1415479]=new thumbnail(1415479,"23848","Moon Gems","My lampwork 1108_thumb.jpg",130,101,18);thumbnails[1415520]=new thumbnail(1415520,"23848","Moon Gem Nuggets","My lampwork 1112w_thumb.jpg",130,98,18);thumbnails[1456475]=new thumbnail(1456475,"23848","Perth Gems","My lampwork 967_thumb.jpg",130,124,18);thumbnails[1463556]=new thumbnail(1463556,"23848","Summer Storm Focal","My lampwork 1224_thumb.jpg",130,117,18);thumbnails[1492039]=new thumbnail(1492039,"23848","Scottish Heather Focal SOLD","My lampwork 1262_thumb.jpg",130,121,18);thumbnails[1492041]=new thumbnail(1492041,"23848","Scottish Heather Set SOLD","My lampwork 1258_thumb.jpg",130,109,18);thumbnails[1492090]=new thumbnail(1492090,"23848","Autumn Focal SOLD","My lampwork 1266_thumb.jpg",130,118,18);thumbnails[1628746]=new thumbnail(1628746,"23848","Bennachie ","My lampwork 861_thumb.jpg",130,127,18);thumbnails[1629379]=new thumbnail(1629379,"23848","Moon Gem Bendy Beads SOLD","My lampwork 1351_thumb.jpg",130,95,18);thumbnails[1629395]=new thumbnail(1629395,"23848","Beach Pebbles SOLD","My lampwork 1374_thumb.jpg",130,106,18);thumbnails[1629422]=new thumbnail(1629422,"23848","Raku Pillows SOLD","My lampwork 1371_thumb.jpg",130,118,18);thumbnails[1703745]=new thumbnail(1703745,"23848","Alford Amber boro beads SOLD","My lampwork 1389_thumb.jpg",130,98,18);thumbnails[1703747]=new thumbnail(1703747,"23848","Aviemore boro beads SOLD","My lampwork 1392_thumb.jpg",130,111,18);thumbnails[1858529]=new thumbnail(1858529,"23848","Amber Silver bendy","amber_silver_bendy_thumb.jpg",130,90,18);thumbnails[1858530]=new thumbnail(1858530,"23848","Aqua bendy","aqua_bendy_thumb.jpg",130,94,18);thumbnails[1858531]=new thumbnail(1858531,"23848","Kronos Black bendy","kronos_black_bendy_thumb.jpg",130,116,18);thumbnails[1858542]=new thumbnail(1858542,"23848","Pink Opal bendy bracelet","My lampwork 5_thumb.jpg",130,98,18);thumbnails[1858549]=new thumbnail(1858549,"23848","Chainmaiile  by Hedgeland Jewellery","My lampwork 017_thumb.jpg",130,96,18);thumbnails[1858554]=new thumbnail(1858554,"23848","Black Peacock bendy beads","My lampwork 953_1_thumb.jpg",130,105,18);thumbnails[2059018]=new thumbnail(2059018,"23848","Midnight Garden Lentil SOLD","My lampwork 1473w_thumb.jpg",130,121,18);thumbnails[2163225]=new thumbnail(2163225,"23848","Shining Sea focal SOLD","My lampwork 1573_thumb.jpg",130,120,18);thumbnails[2213448]=new thumbnail(2213448,"23848","Malachite Glow focal SOLD","My lampwork 1598_thumb.jpg",130,121,18);thumbnails[2213757]=new thumbnail(2213757,"23848","Verdigris focal SOLD","My lampwork 1609_thumb.jpg",130,118,18);thumbnails[2214251]=new thumbnail(2214251,"23848","Moonlight Mystery focal SOLD","My lampwork 1604_thumb.jpg",130,133,18);thumbnails[2214267]=new thumbnail(2214267,"23848","Strata focal SOLD","My lampwork 1600_thumb.jpg",130,122,18);thumbnails[2332491]=new thumbnail(2332491,"23848","Mermaid large focal","My lampwork 1719_thumb.jpg",130,132,18);thumbnails[2482704]=new thumbnail(2482704,"23848","Splendour heart SOLD","My lampwork 1802_thumb.jpg",130,132,18);thumbnails[2482722]=new thumbnail(2482722,"23848","Ebb Tide focal SOLD","My lampwork 1796_thumb.jpg",130,115,18);thumbnails[2482772]=new thumbnail(2482772,"23848","Ruffled Pebble focal SOLD","My lampwork 1791_thumb.jpg",130,109,18);thumbnails[2482790]=new thumbnail(2482790,"23848","Triton Jewels set SOLD","My lampwork 1784_thumb.jpg",130,110,18);thumbnails[1451740]=new thumbnail(1451740,"23848","Orchids SOLD","My lampwork 1210_thumb.jpg",130,116,18);thumbnails[1463540]=new thumbnail(1463540,"23848","Bird of Paradise ","My lampwork 1237_thumb.jpg",130,107,18);thumbnails[2041305]=new thumbnail(2041305,"23848","Cherry Blossom","My lampwork 1438_thumb.jpg",130,120,18);thumbnails[2532643]=new thumbnail(2532643,"23848","Terra Ribbons focal SOLD","My lampwork 1817_thumb.jpg",130,124,18);thumbnails[1451731]=new thumbnail(1451731,"23848","Tendrils ","My lampwork 1213_thumb.jpg",130,99,18);thumbnails[1451716]=new thumbnail(1451716,"23848","Mossy Pebbles","My lampwork 1207_thumb.jpg",130,113,18);thumbnails[1441855]=new thumbnail(1441855,"23848","Psyche Jewels ","My lampwork 1218_thumb.jpg",130,114,18);thumbnails[1006211]=new thumbnail(1006211,"23848","Summer Skies","spring 053_thumb.jpg",130,138,18);thumbnails[1441884]=new thumbnail(1441884,"23848","Glengarnock Mists SOLD","My lampwork 1196_thumb.jpg",130,119,18);thumbnails[449100]=new thumbnail(449100,"23848","Amber Silver Lentils","amber_silver_lentil_cl_thumb.jpg",130,98,18);thumbnails[448435]=new thumbnail(448435,"23848","Chameleon Raku Focal","rakuflower_thumb.jpg",130,111,18);thumbnails[448452]=new thumbnail(448452,"23848","Tapestry","tapestry3_thumb.jpg",130,98,18);var galleries=new Object();galleries[36902]=new gallery(36902,"4999344,4999285,4999278,4999273,4999259","New Beads","gallery",[4999259,4999273,4999278,4999285,4999344]);galleries[75812]=new gallery(75812,"3482558,3482528,3482509,3482507,3482505","Boro Beads ","gallery",[3482505,3482507,3482509,3482528,3482558]);galleries[47801]=new gallery(47801,"","Curved Beads","section53237",[]);galleries[35559]=new gallery(35559,"4818809,4818603,4514128,3935874,3482563,3482531,3482500","Sets","gallery",[3482500,3482531,3482563,3935874,4514128,4818603,4818809]);galleries[35601]=new gallery(35601,"4818875,4818822,4818797,4818674,4554828,4554789,4514121,4513930,3935883,3935688","Pendant Beads and Focals","gallery",[2163159,2163197,2332278,2744639,3482513,3482515,3935688,3935883,4513930,4514121,4554789,4554828,4818674,4818797,4818822,4818875,2041313,2483095]);galleries[101042]=new gallery(101042,"2214468,1492036,1464551,1464535,1464533,1464530,1464529,1464519","Bead Shapes","gallery",[1464519,1464529,1464530,1464533,1464535,1464551,1492036,2214468]);galleries[35610]=new gallery(35610,"","Ready to Wear","section53237",[]);galleries[23848]=new gallery(23848,"2482704,1451731,546025,449100","Gallery","gallery",[449350,449352,449354,449513,466600,494365,531807,546025,769334,828319,828324,1012900,1017345,1058132,1058137,1058143,1067033,1068079,1415479,1415520,1456475,1463556,1492039,1492041,1492090,1628746,1629379,1629395,1629422,1703745,1703747,1858529,1858530,1858531,1858542,1858549,1858554,2059018,2163225,2213448,2213757,2214251,2214267,2332491,2482704,2482722,2482772,2482790,1451740,1463540,2041305,2532643,1451731,1451716,1441855,1006211,1441884,449100,448435,448452]);var imageSets=new Object();imageSets[1]="448182";imageSets[2]="2482704,1451731,546025,449100";imageSets[3]="4818822,4818809,4818797,4818674";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 34:b="http://www9.clikpic.com/weemary/images";break}switch(a){case 1:b="http://www1.clikpic.com/weemary/images";break}switch(a){case 2:b="http://admin.clikpic.com/weemary/images";break}switch(a){case 4:b="http://www.clikchurch.com/weemary/images";break}switch(a){case 5:b="http://www2.clikpic.com/weemary/images";break}switch(a){case 15:b="http://www3.clikpic.com/weemary/images";break}switch(a){case 21:b="http://www6.clikpic.com/weemary/images";break}switch(a){case 18:b="http://www4.clikpic.com/weemary/images";break}switch(a){case 19:b="http://www5.clikpic.com/weemary/images";break}switch(a){case 22:b="http://tpc5/clikpic/weemary/images";break}switch(a){case 23:b="http://tpc10/clikpic/weemary/images";break}switch(a){case 24:b="http://tpc15/clikpic/weemary/images";break}switch(a){case 25:b="http://tpc16/clikpic/weemary/images";break}switch(a){case 31:b="http://www7.clikpic.com/weemary/images";break}switch(a){case 32:b="http://admin2.clikpic.com/weemary/images";break}switch(a){case 33:b="http://www8.clikpic.com/weemary/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="Flamingo Beads: "+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>"}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="mary@dmparker.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="mary@dmparker.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(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+'")'})}}};