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[179048]=new thumbnail(179048,"220230","'What?'","portrait_light_thumb.jpg",130,155,1);thumbnails[179067]=new thumbnail(179067,"220230","Solitude and space","mannequin 007_thumb.jpg",130,130,1);thumbnails[179077]=new thumbnail(179077,"220228","'La Pierre Percée' (pierced rock)","La Pierre Percee sml_thumb.jpg",130,160,1);thumbnails[190183]=new thumbnail(190183,"220230","Waiting","mannequin 013_thumb.jpg",130,195,1);thumbnails[335994]=new thumbnail(335994,"220228","Harvest - belledonne mountains","mannequin 005_thumb.jpg",130,160,1);thumbnails[372257]=new thumbnail(372257,"220228","Centre ville, Bourg D'Oisans","painting 001_thumb.jpg",130,130,1);thumbnails[372263]=new thumbnail(372263,"220228","Bourg D'Oisans cemetary and the Belledonne","painting 002_thumb.jpg",130,173,1);thumbnails[416485]=new thumbnail(416485,"220228","L'eglise de ferréol, Huez","painting 0011_thumb.jpg",130,160,1);thumbnails[542802]=new thumbnail(542802,"220228","Belledonne mountains, Les Sables","belledonne snow_thumb.jpg",130,104,1);thumbnails[737056]=new thumbnail(737056,"220230","Time-piece","ps revised_thumb.jpg",130,195,1);thumbnails[916533]=new thumbnail(916533,"220228","Dethick church - dated 14th century","dethick churchSML_thumb.jpg",130,130,1);thumbnails[1051328]=new thumbnail(1051328,"220228","Small tree study (with Eastwood church on the horizon)","sycamore small 2_thumb.jpg",130,163,1);thumbnails[1224438]=new thumbnail(1224438,"220228","morning calm","eglise st theoffrey_thumb.jpg",130,247,1);thumbnails[1249982]=new thumbnail(1249982,"220228","eglise, afternoon light","eglise st theoffrey 3sml_thumb.jpg",130,157,1);thumbnails[1484995]=new thumbnail(1484995,"220230","'Rosemary McKie'","rmsmall_thumb.jpg",130,130,1);thumbnails[1697873]=new thumbnail(1697873,"220230","'Zara'","zara complete_thumb.jpg",130,186,1);thumbnails[1818657]=new thumbnail(1818657,"220230","Genevieve","genevieve_thumb.jpg",130,173,1);thumbnails[2185464]=new thumbnail(2185464,"220230","Oscar","Untitled-1_thumb.jpg",130,173,1);thumbnails[2239341]=new thumbnail(2239341,"220230","Rosie","rosiesml_thumb.jpg",130,173,1);thumbnails[2363231]=new thumbnail(2363231,"220230","Hugo","hugosml_thumb.jpg",130,173,1);thumbnails[2673646]=new thumbnail(2673646,"220230","Tom","tomsml1_thumb.jpg",130,173,1);thumbnails[3557489]=new thumbnail(3557489,"217662","Seb1","seb1sml_thumb.jpg",130,184,1);thumbnails[3557491]=new thumbnail(3557491,"217662","Cat1","cat1sml_thumb.jpg",130,182,1);thumbnails[3564836]=new thumbnail(3564836,"217662","Aristo1","aristo1sml_thumb.jpg",130,184,1);thumbnails[3599624]=new thumbnail(3599624,"217662","Lo","lbsml_thumb.jpg",130,184,1);thumbnails[3608746]=new thumbnail(3608746,"217662","The Bouncer, Mark III","seb2sml_thumb.jpg",130,184,1);thumbnails[3612282]=new thumbnail(3612282,"220230","Thought, 2003","a_thought_thumb.jpg",130,98,1);thumbnails[3612291]=new thumbnail(3612291,"220230","Wolf","wolf_thumb.jpg",130,104,1);thumbnails[3612296]=new thumbnail(3612296,"220228","'1960-2007'","born1960died2007sml_thumb.jpg",130,109,1);thumbnails[3612362]=new thumbnail(3612362,"220228","Villard Notre Dame","villard_notre_damesml_thumb.jpg",130,160,1);thumbnails[3612376]=new thumbnail(3612376,"220228","L'eglise les sables","l_eglise_des_sablessml_thumb.jpg",130,160,1);thumbnails[3612438]=new thumbnail(3612438,"220228","Early french landscape 'tete de chien'","tete_de_chiensml_thumb.jpg",130,260,1);thumbnails[3612448]=new thumbnail(3612448,"220228","Eastwood / Oaktree","eastwoodsml_thumb.jpg",130,104,1);thumbnails[3612450]=new thumbnail(3612450,"220228","Sycamore tree nr Heanor","treesml_thumb.jpg",130,142,1);thumbnails[3612476]=new thumbnail(3612476,"220230","On campaign","photo_003_thumb.jpg",130,128,1);thumbnails[3612480]=new thumbnail(3612480,"220230","reflection","photo_009sml_thumb.jpg",130,130,1);thumbnails[3613225]=new thumbnail(3613225,"220230","View from the A6","journey1_thumb.jpg",130,84,1);thumbnails[3613238]=new thumbnail(3613238,"220230","Dream, 2004","d_thumb.jpg",130,169,1);thumbnails[3613241]=new thumbnail(3613241,"220230","Protection, 2005","e_thumb.jpg",130,190,1);thumbnails[3613249]=new thumbnail(3613249,"220230","Chair and lamp, Manchester","chairlamp_thumb.jpg",130,183,1);thumbnails[3616453]=new thumbnail(3616453,"217662","Marco-silver","marcosilversml_thumb.jpg",130,184,1);thumbnails[3621406]=new thumbnail(3621406,"217662","marcosilver 'look away'","marcosilver2sml_thumb.jpg",130,184,1);thumbnails[3633865]=new thumbnail(3633865,"217662","beautiful people","cat3sml3_thumb.jpg",130,182,1);thumbnails[4319601]=new thumbnail(4319601,"220230","Still-life 'Derek and Patricia'","still-life_double-portrait_thumb.jpg",130,93,1);thumbnails[4319670]=new thumbnail(4319670,"220228","Algrave Hall, Summer day","algrave_oil-sketch_sml_thumb.jpg",130,110,1);thumbnails[4556824]=new thumbnail(4556824,"220228","kitchen garden, ","kitchengardensml_thumb.jpg",130,162,1);thumbnails[4556834]=new thumbnail(4556834,"220228","View overlooking Eastwood, Derbyshire","dyptichsml_thumb.jpg",130,50,1);thumbnails[5222592]=new thumbnail(5222592,"","Oil painting Guide - Project 1 'Still-life'","oil_painting_guide-1_thumb.jpg",130,189,1);thumbnails[5222869]=new thumbnail(5222869,"220230","'Elvis' - Part of a large tryptic commission","elvis_thumb.jpg",130,260,1);thumbnails[5222922]=new thumbnail(5222922,"220230","'Marilyn Mansun' - part of a large tryptic commission","mansun_thumb.jpg",130,260,1);thumbnails[5222935]=new thumbnail(5222935,"220230","'Slash' - part of a large tryptic commission","slash_thumb.jpg",130,260,1);thumbnails[5596169]=new thumbnail(5596169,"294574","Preston Montford","preston_montford_gates_sml_thumb.jpg",130,104,1);thumbnails[5596171]=new thumbnail(5596171,"294574","Preston Montford, September field.","preston_montford_farmersfield_sml_thumb.jpg",130,104,1);thumbnails[5596173]=new thumbnail(5596173,"294574","Preston Montford, September field, dusk.","preston_montford_farmersfield2_sml_thumb.jpg",130,98,1);thumbnails[5596175]=new thumbnail(5596175,"294574","Painting, Preston Montford","field_trip_thumb.jpg",130,88,1);thumbnails[5596182]=new thumbnail(5596182,"294574","Beginners Guide 'Painting in Oils'","guide1_thumb.jpg",130,141,1);thumbnails[5919547]=new thumbnail(5919547,"220228","Church Light","l_eglise_pierre_chatel_2sml_thumb.jpg",130,195,1);thumbnails[3080506]=new thumbnail(3080506,"328234","Sight-size drawing.","sitesize2sml_thumb.jpg",130,201,1);thumbnails[5792701]=new thumbnail(5792701,"163352","Life Drawings. Chalk, conte or charcoal on paper","IMG_0014_copy_thumb.jpg",130,191,1);thumbnails[5792702]=new thumbnail(5792702,"163352","Life Drawings. Chalk, conte or charcoal on paper","IMG_0015_copy_thumb.jpg",130,249,1);thumbnails[5792703]=new thumbnail(5792703,"163352","Life Drawings. Chalk, conte or charcoal on paper","IMG_0016_copy_thumb.jpg",130,196,1);thumbnails[5792706]=new thumbnail(5792706,"163352","Life Drawings. Chalk, conte or charcoal on paper","IMG_0017x_thumb.JPG",130,188,1);thumbnails[5792707]=new thumbnail(5792707,"163352","Life Drawings. Chalk, conte or charcoal on paper","IMG_0018_copy_thumb.jpg",130,196,1);thumbnails[5792708]=new thumbnail(5792708,"163352","Life Drawings. Chalk, conte or charcoal on paper","IMG_0019_copy_thumb.jpg",130,184,1);thumbnails[5792710]=new thumbnail(5792710,"163352","Life Drawings. Chalk, conte or charcoal on paper","IMG_0021_copy_thumb.jpg",130,178,1);thumbnails[5792712]=new thumbnail(5792712,"163352","Life Drawings. Chalk, conte or charcoal on paper","IMG_0021x_thumb.JPG",130,101,1);thumbnails[5792713]=new thumbnail(5792713,"163352","Life Drawings. Chalk, conte or charcoal on paper","IMG_0022_copy_thumb.jpg",130,181,1);thumbnails[5792714]=new thumbnail(5792714,"163352","Life Drawings. Chalk, conte or charcoal on paper","IMG_0023_copy_thumb.jpg",130,82,1);thumbnails[5792715]=new thumbnail(5792715,"163352","Life Drawings. Chalk, conte or charcoal on paper","IMG_0011_thumb.JPG",130,169,1);thumbnails[5792730]=new thumbnail(5792730,"163352","Life Drawings. Chalk, conte or charcoal on paper","IMG_0013_thumb.JPG",130,163,1);thumbnails[5919782]=new thumbnail(5919782,"163352","Life Drawings. Chalk, conte or charcoal on paper","IMG_0049_thumb.jpg",130,96,1);thumbnails[5919783]=new thumbnail(5919783,"163352","Life Drawings. Chalk, conte or charcoal on paper","IMG_0043a_thumb.jpg",130,176,1);thumbnails[5919784]=new thumbnail(5919784,"163352","Life Drawings. Chalk, conte or charcoal on paper","IMG_0041a_thumb.jpg",130,95,1);thumbnails[5919786]=new thumbnail(5919786,"163352","Life Drawings. Chalk, conte or charcoal on paper","IMG_0044a1_thumb.jpg",130,97,1);thumbnails[5928739]=new thumbnail(5928739,"163352","Conte on paper","IMG_0047_thumb.jpg",130,173,1);thumbnails[5928741]=new thumbnail(5928741,"163352","Conte on paper","IMG_0048a_thumb.jpg",130,97,1);thumbnails[5928742]=new thumbnail(5928742,"163352","Conte on paper","IMG_0053a_thumb.jpg",130,95,1);thumbnails[5928743]=new thumbnail(5928743,"163352","Conte on paper","IMG_0052a_thumb.jpg",130,179,1);thumbnails[6146440]=new thumbnail(6146440,"163352","","IMG_0017A_thumb.jpg",130,92,1);thumbnails[6146521]=new thumbnail(6146521,"163352","","IMG_0018A_thumb.jpg",130,91,1);thumbnails[6146541]=new thumbnail(6146541,"163352","","IMG_0019A_thumb.jpg",130,93,1);thumbnails[3167910]=new thumbnail(3167910,"16444","Brass and wood","pestle mortarsml_thumb.jpg",130,156,1);thumbnails[3219111]=new thumbnail(3219111,"16444","Norwegian pewter","pewtersmler_thumb.jpg",130,156,1);thumbnails[3326101]=new thumbnail(3326101,"16444","China tea","china teasml_thumb.jpg",130,89,1);thumbnails[3431288]=new thumbnail(3431288,"16444","lava lamp","lavalamp daylightsml1_thumb.jpg",130,160,1);thumbnails[4550147]=new thumbnail(4550147,"16444","Sink","shavesml_thumb.jpg",130,104,1);thumbnails[4700855]=new thumbnail(4700855,"16444","Impression skull 2","impression_skull_2sml_thumb.jpg",130,157,1);thumbnails[5054998]=new thumbnail(5054998,"16444","Jean Matayac","jean_matayac_sml_thumb.jpg",130,157,1);thumbnails[5266040]=new thumbnail(5266040,"16444","Hermes of orange","hermestheorangesml_thumb.jpg",130,156,1);thumbnails[222642]=new thumbnail(222642,"263377","Decision","thoughtssml_thumb.jpg",130,98,1);thumbnails[2883810]=new thumbnail(2883810,"263377","number nine","sp9_thumb.jpg",130,130,1);thumbnails[2911073]=new thumbnail(2911073,"263377","number fifteen","sp15_thumb.jpg",130,130,1);thumbnails[3319348]=new thumbnail(3319348,"263377","will-power","selfportrait jan 2009sml_thumb.jpg",130,197,1);thumbnails[3326112]=new thumbnail(3326112,"263377","Standing, looking down","begining of beginingsml_thumb.jpg",130,190,1);thumbnails[3528208]=new thumbnail(3528208,"263377","The Mask","the mask1sml_thumb.jpg",130,188,1);thumbnails[3612268]=new thumbnail(3612268,"263377","Old selfportrait, 2003","flash8_thumb.jpg",130,169,1);thumbnails[3613181]=new thumbnail(3613181,"263377","2 days","selfportrait2008bsml_thumb.jpg",130,156,1);thumbnails[5909223]=new thumbnail(5909223,"263377","Conte on paper","selfportrait_may_2010sml_thumb.jpg",130,184,1);thumbnails[5915542]=new thumbnail(5915542,"263377","Conte on paper","selfportrait_may_2010_number3sml_thumb.jpg",130,156,1);thumbnails[5946412]=new thumbnail(5946412,"263377","Conte on paper","selfportrait_may_2010_number4sml_thumb.jpg",130,183,1);var galleries=new Object();galleries[226321]=new gallery(226321,"","Business cards","section276963",[]);galleries[220230]=new gallery(220230,"1484995,737056","Commissions and miscellaneous","gallery",[179048,179067,190183,737056,1484995,1697873,1818657,2185464,2239341,2363231,2673646,3612282,3612291,3612476,3612480,3613225,3613238,3613241,3613249,4319601,5222869,5222922,5222935]);galleries[226320]=new gallery(226320,"","Flyers","section276963",[]);galleries[220228]=new gallery(220228,"5919547,4556834,4556824,4319670,3612450,3612448,3612438,3612376,3612362,3612296","Landscapes","gallery",[179077,335994,372257,372263,416485,542802,916533,1051328,1224438,1249982,3612296,3612362,3612376,3612438,3612448,3612450,4319670,4556824,4556834,5919547]);galleries[226319]=new gallery(226319,"","logos","section276963",[]);galleries[226521]=new gallery(226521,"","Shop fascia","section276963",[]);galleries[217662]=new gallery(217662,"3633865,3621406,3616453,3608746,3599624,3564836,3557491,3557489","Studies for portraits","gallery",[3557489,3557491,3564836,3599624,3608746,3616453,3621406,3633865]);galleries[294574]=new gallery(294574,"5596182,5596175,5596173,5596171,5596169","Weekend workshops","section352389",[5596169,5596171,5596173,5596175,5596182]);galleries[328234]=new gallery(328234,"3080506","Classical drawings","gallery",[3080506]);galleries[163352]=new gallery(163352,"6146541,6146521,6146440,5928743,5928742,5928741,5928739,5919786,5919784,5919783","Life drawings","gallery",[5792701,5792702,5792703,5792706,5792707,5792708,5792710,5792712,5792713,5792714,5792715,5792730,5919782,5919783,5919784,5919786,5928739,5928741,5928742,5928743,6146440,6146521,6146541]);galleries[16444]=new gallery(16444,"5266040,5054998,4700855,4550147,3431288,3326101,3219111,3167910","Paintings","gallery",[3167910,3219111,3326101,3431288,4550147,4700855,5054998,5266040]);galleries[263377]=new gallery(263377,"5946412,5915542,5909223,3613181,3612268,3528208,3326112,3319348,2911073,2883810","Self portraits","gallery",[222642,2883810,2911073,3319348,3326112,3528208,3612268,3613181,5909223,5915542,5946412]);var imageSets=new Object();imageSets[1]="5792730,5792715,5792714,5792713,5792712,5792710,5792708,5792707,5792706,5792703,5792702,5792701,5266040,4700855,4550147,4319670,3564836,3557491,3557489,3528208,3431288,3326112,3326101,3319348,3167910,3080506,1697873,1484995,222642,190183";imageSets[2]="1484995,737056";imageSets[3]="6146541,6146521,6146440,5946412,5928743,5928742,5928741,5928739,5919786,5919784,5919783,5919782,5919547,5915542,5909223,5792730,5792715,5792714,5792713,5792712,5792710,5792708,5792707,5792706,5792703,5792702,5792701,5596182,5596175,5596173,5596171,5596169,5266040,5222935,5222922,5222869,5222592,5054998,4700855,4556834,4556824,4550147,4319670,4319601,3633865,3621406,3616453,3613249,3613241,3613238";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/robinperko/images";break}switch(a){case 1:b="http://www1.clikpic.com/robinperko/images";break}switch(a){case 2:b="http://admin.clikpic.com/robinperko/images";break}switch(a){case 24:b="http://tpc15/clikpic/robinperko/images";break}switch(a){case 4:b="http://www.clikchurch.com/robinperko/images";break}switch(a){case 5:b="http://www2.clikpic.com/robinperko/images";break}switch(a){case 22:b="http://tpc5/clikpic/robinperko/images";break}switch(a){case 23:b="http://tpc10/clikpic/robinperko/images";break}switch(a){case 25:b="http://tpc16/clikpic/robinperko/images";break}switch(a){case 15:b="http://www3.clikpic.com/robinperko/images";break}switch(a){case 18:b="http://www4.clikpic.com/robinperko/images";break}switch(a){case 19:b="http://www5.clikpic.com/robinperko/images";break}switch(a){case 31:b="http://www7.clikpic.com/robinperko/images";break}switch(a){case 32:b="http://admin2.clikpic.com/robinperko/images";break}switch(a){case 33:b="http://www8.clikpic.com/robinperko/images";break}switch(a){case 34:b="http://www9.clikpic.com/robinperko/images";break}switch(a){case 35:b="http://admin3.clikpic.com/robinperko/images";break}switch(a){case 37:b="http://admin4.clikpic.com/robinperko/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="robinperko.com: "+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> 				&euro;"+(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="rmperko@hotmail.com">';b=b+'<input type="hidden" name="currency_code" value="EUR">';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="rmperko@hotmail.com">';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+'")'})}}};