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[2519276]=new thumbnail(2519276,"","","me_thumb.jpg",130,130,1);thumbnails[2714760]=new thumbnail(2714760,"","","button_illy_thumb.jpg",130,43,1);thumbnails[2714761]=new thumbnail(2714761,"","","button_lino_thumb.jpg",130,41,1);thumbnails[2719287]=new thumbnail(2719287,"","","button_mono_thumb.jpg",130,29,1);thumbnails[3472111]=new thumbnail(3472111,"","","bloglogo_thumb.jpg",30,30,1);thumbnails[5093572]=new thumbnail(5093572,"","","AOI_Logo_Member_278c_Blk_thumb.jpg",130,46,1);thumbnails[5626045]=new thumbnail(5626045,"","","boot-home_thumb.jpg",130,130,1);thumbnails[6325611]=new thumbnail(6325611,"","","handsome_frank_logo-1_thumb.jpg",50,44,1);thumbnails[5994672]=new thumbnail(5994672,"337446","","BWFillus-1_thumb.jpg",130,130,1);thumbnails[5994677]=new thumbnail(5994677,"337446","","BWF-Illo8_thumb.jpg",130,130,1);thumbnails[5994744]=new thumbnail(5994744,"337446","","BWf-illus10_thumb.jpg",130,130,1);thumbnails[5994750]=new thumbnail(5994750,"337446","","BWF-illo13_thumb.jpg",130,130,1);thumbnails[5994682]=new thumbnail(5994682,"337446","","BWFborders_thumb.jpg",130,130,1);thumbnails[5994927]=new thumbnail(5994927,"337446","","BWFborders2_thumb.jpg",130,130,1);thumbnails[3313457]=new thumbnail(3313457,"","","homeillustration_thumb.jpg",130,87,1);thumbnails[2657388]=new thumbnail(2657388,"","","homelacuna_thumb.jpg",130,130,1);thumbnails[2657387]=new thumbnail(2657387,"","","homePENMAN-copy2_thumb.jpg",130,130,1);thumbnails[2657385]=new thumbnail(2657385,"","","homebluegrass_thumb.jpg",130,130,1);thumbnails[2657390]=new thumbnail(2657390,"","","homezebra_thumb.jpg",130,130,1);thumbnails[5994669]=new thumbnail(5994669,"168876","","BWFCover_thumb.jpg",130,130,1);thumbnails[6213559]=new thumbnail(6213559,"168876","","HeadlightsFinal_thumb.jpg",130,130,1);thumbnails[5360986]=new thumbnail(5360986,"168876","","GHOSTRIDER-Final_thumb.jpg",130,130,1);thumbnails[5360935]=new thumbnail(5360935,"168876","","fruitselection_thumb.jpg",130,130,1);thumbnails[3576714]=new thumbnail(3576714,"168876","","mobydickW-spineJPG_thumb.jpg",130,130,1);thumbnails[3431007]=new thumbnail(3431007,"168876","","bambi_thumb.jpg",130,130,1);thumbnails[2657355]=new thumbnail(2657355,"168876","","PENMAN-copy1_thumb.jpg",130,130,1);thumbnails[2514704]=new thumbnail(2514704,"168876","","lacunacover_thumb.jpg",130,130,1);thumbnails[2514963]=new thumbnail(2514963,"168876","","peteleonardcover_thumb.jpg",130,130,1);thumbnails[2515340]=new thumbnail(2515340,"168876","","dogman_thumb.jpg",130,130,1);thumbnails[2515324]=new thumbnail(2515324,"168876","","dogbone_thumb.jpg",130,130,1);thumbnails[2515419]=new thumbnail(2515419,"168876","","stepmother_thumb.jpg",130,130,1);thumbnails[2515406]=new thumbnail(2515406,"168876","","greatfire_thumb.jpg",130,130,1);thumbnails[3953996]=new thumbnail(3953996,"168878","","kingsjustice_insitu_thumb.jpg",130,130,1);thumbnails[3954005]=new thumbnail(3954005,"168878","","kingsjustice2_insitu_thumb.jpg",130,130,1);thumbnails[5360957]=new thumbnail(5360957,"168878","","Whorwood_6sl_thumb.jpg",130,130,1);thumbnails[5976287]=new thumbnail(5976287,"168878","","diggers_thumb.jpg",130,130,1);thumbnails[6213582]=new thumbnail(6213582,"168878","","SIGH_AUG_COVER_thumb.jpg",130,130,1);thumbnails[3199422]=new thumbnail(3199422,"168878","","sagittarius+text-copy_thumb.jpg",127,126,1);thumbnails[3199421]=new thumbnail(3199421,"168878","","pisces+text-copy_thumb.jpg",130,130,1);thumbnails[3199419]=new thumbnail(3199419,"168878","","aquarius+text-copy_thumb.jpg",130,130,1);thumbnails[2515018]=new thumbnail(2515018,"168878","","the-hunt_thumb.jpg",130,130,1);thumbnails[2515471]=new thumbnail(2515471,"168878","","HorseI12_thumb.jpg",130,130,1);thumbnails[2515477]=new thumbnail(2515477,"168878","","johnsmithlight_thumb.jpg",130,130,1);thumbnails[3631058]=new thumbnail(3631058,"81643","","redridinghood_thumb.jpg",130,130,1);thumbnails[2542628]=new thumbnail(2542628,"81643","","Chess_thumb.jpg",130,130,1);thumbnails[2516372]=new thumbnail(2516372,"81643","","osprey_thumb.jpg",130,130,1);thumbnails[3312658]=new thumbnail(3312658,"81643","","Rapunzel_thumb.jpg",130,130,1);thumbnails[2516378]=new thumbnail(2516378,"81643","","phaedrus_thumb.jpg",130,130,1);thumbnails[2516335]=new thumbnail(2516335,"81643","","greenman_thumb.jpg",130,130,1);thumbnails[2516420]=new thumbnail(2516420,"81643","","leopard-spots_thumb.jpg",130,130,1);thumbnails[2516473]=new thumbnail(2516473,"81643","","sanxaviersnail_thumb.jpg",130,130,1);thumbnails[2516380]=new thumbnail(2516380,"81643","","zebra_print_thumb.jpg",130,130,1);thumbnails[2515429]=new thumbnail(2515429,"81643","","giants_thumb.jpg",130,130,1);thumbnails[3604642]=new thumbnail(3604642,"168877","","woodblewits_thumb.jpg",130,130,1);thumbnails[3197240]=new thumbnail(3197240,"168877","","beetroot_thumb.jpg",130,130,1);thumbnails[3041416]=new thumbnail(3041416,"168877","","springonions_thumb.jpg",130,130,1);thumbnails[3041414]=new thumbnail(3041414,"168877","","pomegranate_thumb.jpg",130,130,1);thumbnails[3041411]=new thumbnail(3041411,"168877","","lemons_thumb.jpg",130,130,1);thumbnails[3041409]=new thumbnail(3041409,"168877","","coriander_thumb.jpg",130,130,1);thumbnails[2794034]=new thumbnail(2794034,"168877","","sweetcorn_thumb.jpg",130,130,1);thumbnails[3034503]=new thumbnail(3034503,"168877","","lemonsYellow_thumb.jpg",130,130,1);thumbnails[2791481]=new thumbnail(2791481,"168877","","onions_thumb.jpg",130,130,1);thumbnails[2762188]=new thumbnail(2762188,"168877","","cucumber_flat_thumb.jpg",130,130,1);thumbnails[2516685]=new thumbnail(2516685,"161207","","boobies_thumb.jpg",130,130,1);thumbnails[2516687]=new thumbnail(2516687,"161207","","fuzzymen_thumb.jpg",130,130,1);thumbnails[2516694]=new thumbnail(2516694,"161207","","puff-puff_thumb.jpg",130,130,1);thumbnails[2553983]=new thumbnail(2553983,"161207","","sparrows_thumb.jpg",130,130,1);thumbnails[3302584]=new thumbnail(3302584,"161207","","nuthatch_thumb.jpg",130,130,1);thumbnails[3954147]=new thumbnail(3954147,"161207","","seeyoujimmy_thumb.jpg",130,130,1);thumbnails[4292462]=new thumbnail(4292462,"161207","","balu_thumb.jpg",130,130,1);thumbnails[4292465]=new thumbnail(4292465,"161207","","hip-hop-seagull_thumb.jpg",130,130,1);thumbnails[4292466]=new thumbnail(4292466,"161207","","show-off_thumb.jpg",130,130,1);thumbnails[4292468]=new thumbnail(4292468,"161207","","oscar_thumb.jpg",130,130,1);thumbnails[4601392]=new thumbnail(4601392,"161207","","banjotime_thumb.jpg",130,130,1);thumbnails[4601395]=new thumbnail(4601395,"161207","","chilli_thumb.jpg",130,130,1);thumbnails[5360968]=new thumbnail(5360968,"161207","","ducks_thumb.jpg",130,130,1);thumbnails[6353114]=new thumbnail(6353114,"161207","","old-goat_thumb.jpg",130,130,1);thumbnails[5116941]=new thumbnail(5116941,"289142","","xmas_Robin_thumb.jpg",130,130,1);thumbnails[5116944]=new thumbnail(5116944,"289142","","xmas_robin2_thumb.jpg",130,130,1);var galleries=new Object();galleries[337446]=new gallery(337446,"5994927,5994750,5994744,5994682,5994677,5994672","Beowulf","section211111",[5994672,5994677,5994744,5994750,5994682,5994927]);galleries[168876]=new gallery(168876,"3576714,3431007,2514704","Books/music","gallery",[5994669,6213559,5360986,5360935,3576714,3431007,2657355,2514704,2514963,2515340,2515324,2515419,2515406]);galleries[161209]=new gallery(161209,"5360957,3604642,3576714,3431007,3197240,3041416,3041414,3041411,3041409,3034503,2762188,2514704","Illustration","gallery",[]);galleries[168878]=new gallery(168878,"5360957","Editorials","gallery",[3953996,3954005,5360957,5976287,6213582,3199422,3199421,3199419,2515018,2515471,2515477]);galleries[168877]=new gallery(168877,"3604642,3197240,3041416,3041414,3041411,3041409,3034503,2762188","Food","gallery",[3604642,3197240,3041416,3041414,3041411,3041409,2794034,3034503,2791481,2762188]);galleries[81643]=new gallery(81643,"3631058,2516473","Linoprints","gallery",[3631058,2542628,2516372,3312658,2516378,2516335,2516420,2516473,2516380,2515429]);galleries[161207]=new gallery(161207,"3302584,2553983","Monoprints","gallery",[2516685,2516687,2516694,2553983,3302584,3954147,4292462,4292465,4292466,4292468,4601392,4601395,5360968,6353114]);galleries[289142]=new gallery(289142,"5116944,5116941","Misc","gallery",[5116941,5116944]);var imageSets=new Object();imageSets[1]="5626045";imageSets[2]="5360957,3631058,3604642,3576714,3431007,3302584,3197240,3041416,3041414,3041411,3041409,3034503,2762188,2553983,2516473,2514704";imageSets[3]="6353114,6325611,6213582,6213559,5994927,5994750,5994744,5994682,5994677,5994672,5994669,5976287,5626045,5360986,5360968,5360957,5360935,5116944,5116941,5093572,4601395,4601392,4292468,4292466,4292465,4292462,3954147,3954005,3953996,3631058,3604642,3576714,3472111,3431007,3313457,3312658,3302584,3199422,3199421,3199419,3197240,3041416,3041414,3041411,3041409,3034503,2794034,2791481,2762188,2719287";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/beccaj/images";break}switch(a){case 1:b="http://www1.clikpic.com/beccaj/images";break}switch(a){case 2:b="http://admin.clikpic.com/beccaj/images";break}switch(a){case 24:b="http://tpc15/clikpic/beccaj/images";break}switch(a){case 4:b="http://www.clikchurch.com/beccaj/images";break}switch(a){case 5:b="http://www2.clikpic.com/beccaj/images";break}switch(a){case 22:b="http://tpc5/clikpic/beccaj/images";break}switch(a){case 23:b="http://tpc10/clikpic/beccaj/images";break}switch(a){case 25:b="http://tpc16/clikpic/beccaj/images";break}switch(a){case 15:b="http://www3.clikpic.com/beccaj/images";break}switch(a){case 18:b="http://www4.clikpic.com/beccaj/images";break}switch(a){case 19:b="http://www5.clikpic.com/beccaj/images";break}switch(a){case 31:b="http://www7.clikpic.com/beccaj/images";break}switch(a){case 32:b="http://admin2.clikpic.com/beccaj/images";break}switch(a){case 33:b="http://www8.clikpic.com/beccaj/images";break}switch(a){case 34:b="http://www9.clikpic.com/beccaj/images";break}switch(a){case 35:b="http://admin3.clikpic.com/beccaj/images";break}switch(a){case 37:b="http://admin4.clikpic.com/beccaj/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="Becca Thorne Illustrator: "+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+'")'})}}};