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[1786251]=new thumbnail(1786251,"","","Fame-245_thumb.jpg",130,163,1);thumbnails[1786259]=new thumbnail(1786259,"","","GEORGES-002051_thumb.jpg",130,163,1);thumbnails[1786262]=new thumbnail(1786262,"","","PROTEGE-00068_thumb.jpg",130,163,1);thumbnails[1786266]=new thumbnail(1786266,"","","v2PROTOGE-00214_thumb.jpg",130,163,1);thumbnails[2781812]=new thumbnail(2781812,"","","1HOB -124A1_thumb.jpg",130,163,1);thumbnails[2781815]=new thumbnail(2781815,"","","1HOB -2481_thumb.jpg",130,163,1);thumbnails[2781818]=new thumbnail(2781818,"","","1HOB -446_thumb.jpg",130,163,1);thumbnails[2781858]=new thumbnail(2781858,"","","A MCGUIGAN -064_thumb.jpg",130,163,1);thumbnails[2781903]=new thumbnail(2781903,"","","A V1ETHOS-194A4_thumb.jpg",130,163,1);thumbnails[2797176]=new thumbnail(2797176,"","","1HOB MEN-206A1_thumb.jpg",130,163,1);thumbnails[2797177]=new thumbnail(2797177,"","","1HOB MEN-255contrast1_thumb.jpg",130,163,1);thumbnails[2797179]=new thumbnail(2797179,"","","1HOB MEN-293contrats1_thumb.jpg",130,163,1);thumbnails[2797189]=new thumbnail(2797189,"","","B V1ETHOS-096A2_thumb.jpg",130,163,1);thumbnails[2797197]=new thumbnail(2797197,"","","C V1ETHOS-073A3_thumb.jpg",130,163,1);thumbnails[2797206]=new thumbnail(2797206,"","","CIENTE -225_thumb.jpg",130,163,1);thumbnails[2797207]=new thumbnail(2797207,"","","CV11_thumb.jpg",130,163,1);thumbnails[2797209]=new thumbnail(2797209,"","","ETHOS-194A_thumb.jpg",130,82,1);thumbnails[2797229]=new thumbnail(2797229,"","","HOB R2-076final_thumb.jpg",130,163,1);thumbnails[2797240]=new thumbnail(2797240,"","","Mosko-233_thumb.jpg",130,163,1);thumbnails[2797251]=new thumbnail(2797251,"","","TPL R2-154_thumb.jpg",130,163,1);thumbnails[2797252]=new thumbnail(2797252,"","","TPL R2-181_thumb.jpg",130,163,1);thumbnails[2797258]=new thumbnail(2797258,"","","TPL R2-235_thumb.jpg",130,163,1);thumbnails[3269613]=new thumbnail(3269613,"","","ETHOS -156_thumb.jpg",130,163,1);thumbnails[3269614]=new thumbnail(3269614,"","","ETHOS -212_thumb.jpg",130,163,1);thumbnails[3269615]=new thumbnail(3269615,"","","ETHOS -274_thumb.jpg",130,163,1);thumbnails[4824754]=new thumbnail(4824754,"291712","north west","ETHOS_R2-057_thumb.jpg",130,163,1);thumbnails[4824757]=new thumbnail(4824757,"291712","north west","ETHOS_R2-122_thumb.jpg",130,163,1);thumbnails[4824758]=new thumbnail(4824758,"291712","north west","ETHOS_R2-154_thumb.jpg",130,163,1);thumbnails[4824762]=new thumbnail(4824762,"291712","north west","ETHOS-186print_thumb.jpg",130,163,1);thumbnails[4824790]=new thumbnail(4824790,"291712","london","HOB-624on_day_f6_thumb.jpg",130,163,1);thumbnails[4824805]=new thumbnail(4824805,"291712","artisitic team","HOBBS01_S13_0001_f8art_thumb.jpg",130,184,1);thumbnails[5165526]=new thumbnail(5165526,"291712","london","HOBBS01_S19_0017_f5_thumb.jpg",130,163,1);thumbnails[5165694]=new thumbnail(5165694,"291712","north west","ETHOS-029print2_thumb.jpg",130,163,1);thumbnails[5165695]=new thumbnail(5165695,"291712","artistic team","HOB-493on_day_f4_30C8F99A-2219-B5B5-4CBC38A0A336D4A3_thumb.jpg",130,184,1);thumbnails[5165696]=new thumbnail(5165696,"291712","london","HOBBS01_S12_0035_f51_thumb.jpg",130,163,1);thumbnails[5165528]=new thumbnail(5165528,"291712","artistic team","HOBBS01_S22_0020_f5_thumb.jpg",130,163,1);thumbnails[4824775]=new thumbnail(4824775,"291712","artistic team","HOB-046on_day_f5_thumb.jpg",130,184,1);thumbnails[4824807]=new thumbnail(4824807,"291712","artistic team","HOBBS01_S15_0037_f5_thumb.jpg",130,184,1);thumbnails[4824788]=new thumbnail(4824788,"291712","artistic team","HOB-595on_day_f6_thumb.jpg",130,163,1);thumbnails[4824792]=new thumbnail(4824792,"291712","artistic team","HOB-653on_day_f5_thumb.jpg",130,184,1);thumbnails[4824799]=new thumbnail(4824799,"291712","artistic team","HOBBS01_S07_0019_f5_thumb.jpg",130,184,1);thumbnails[4824723]=new thumbnail(4824723,"254087","","AM-3751st_pick_thumb.jpg",130,163,1);thumbnails[4824725]=new thumbnail(4824725,"254087","","Burlesque_R2_116_thumb.jpg",130,184,1);thumbnails[4824733]=new thumbnail(4824733,"254087","","Burlesque-166_thumb.jpg",130,173,1);thumbnails[4824735]=new thumbnail(4824735,"254087","","CF016726on_day_thumb.jpg",130,92,1);thumbnails[4824737]=new thumbnail(4824737,"254087","","CF017609_thumb.jpg",130,184,1);thumbnails[4824740]=new thumbnail(4824740,"254087","","DIVA_R2-271_cropped_thumb.jpg",130,163,1);thumbnails[4824795]=new thumbnail(4824795,"254087","","HOB-688on_day_f5_thumb.jpg",130,184,1);thumbnails[4824801]=new thumbnail(4824801,"254087","","HOBBS01_S08_0068_f5sean_thumb.jpg",130,184,1);thumbnails[4824808]=new thumbnail(4824808,"254087","","HOBBS01_S17_0001_f4_thumb.jpg",130,163,1);thumbnails[5165313]=new thumbnail(5165313,"254087","","BOONS-078jr_thumb.jpg",130,184,1);thumbnails[5165314]=new thumbnail(5165314,"254087","","BOONS-185jr_thumb.jpg",130,184,1);thumbnails[1544233]=new thumbnail(1544233,"67564","","Creative Head - Nov 07_thumb.jpg",130,179,1);thumbnails[1544237]=new thumbnail(1544237,"67564","","Fellowship copy_thumb.jpg",130,173,1);thumbnails[1831227]=new thumbnail(1831227,"67564","","Creative Head - Oct 07 002_1_thumb.jpg",130,179,1);thumbnails[1831234]=new thumbnail(1831234,"67564","","Hair Ideas - Jan 08 005_thumb.jpg",130,95,1);thumbnails[1831254]=new thumbnail(1831254,"67564","","Your Hair - Dec 07 006_thumb.jpg",130,179,1);thumbnails[1832903]=new thumbnail(1832903,"67564","","HJ - 8 Feb 08 002_thumb.jpg",130,179,1);thumbnails[1832904]=new thumbnail(1832904,"67564","","HJ - 8 Feb 08 003_thumb.jpg",130,179,1);thumbnails[1832906]=new thumbnail(1832906,"67564","","HJ - 8 Feb 08 005_thumb.jpg",130,179,1);thumbnails[1833804]=new thumbnail(1833804,"67564","","Creative Head - Feb 08_thumb.jpg",130,179,1);thumbnails[1900952]=new thumbnail(1900952,"67564","","Fellowship Magazine - Feb 08_thumb.jpg",130,179,1);thumbnails[2965418]=new thumbnail(2965418,"67564","","HJA - 17 Oct 08_thumb.jpg",130,214,1);thumbnails[3329079]=new thumbnail(3329079,"67564","","nobu_thumb.jpg",130,78,1);thumbnails[3654540]=new thumbnail(3654540,"67564","","Tribute_-_Spring_09_-0001_thumb.jpg",130,222,1);thumbnails[5363235]=new thumbnail(5363235,"67564","","Professional_Hairdresser_-_jan_100001_thumb.jpg",130,178,1);thumbnails[5363236]=new thumbnail(5363236,"67564","","salon_business_-_jan_100001_thumb.jpg",130,174,1);thumbnails[5524345]=new thumbnail(5524345,"67564","","0003_thumb.jpg",130,168,1);thumbnails[5524364]=new thumbnail(5524364,"67564","","0006_thumb.jpg",130,170,1);thumbnails[5524365]=new thumbnail(5524365,"67564","","Estetica_-_Protagonist0001_thumb.jpg",130,172,1);thumbnails[5524369]=new thumbnail(5524369,"67564","","Professional_Hairdresser_-_Jan_100001_E1BDF826-1D09-001F-9983EE77D571B20D_thumb.jpg",130,174,1);thumbnails[5524370]=new thumbnail(5524370,"67564","","Professional_Hairdresser_-_Jan_100002_thumb.jpg",130,174,1);thumbnails[5524371]=new thumbnail(5524371,"67564","","Professional_Hairdresser_-_Jan_100003_thumb.jpg",130,182,1);thumbnails[5524375]=new thumbnail(5524375,"67564","","Professional_Hairdresser_-_Jan_100007_thumb.jpg",130,180,1);thumbnails[5524378]=new thumbnail(5524378,"67564","","Professional_Hairdresser_-_Jan_100009_thumb.jpg",130,178,1);thumbnails[5524379]=new thumbnail(5524379,"67564","","Salon_Business_-_Colour_20100002_thumb.jpg",130,151,1);thumbnails[5524381]=new thumbnail(5524381,"67564","","Trib-ute_09-100001_thumb.jpg",130,184,1);thumbnails[5524382]=new thumbnail(5524382,"67564","","Trib-ute_09-100002_thumb.jpg",130,179,1);thumbnails[5524383]=new thumbnail(5524383,"67564","","Trib-ute_09-100004_thumb.jpg",130,182,1);thumbnails[5560647]=new thumbnail(5560647,"67564","","HJ_-_26_Feb_100001_thumb.jpg",130,175,1);thumbnails[5560649]=new thumbnail(5560649,"67564","","HJ_-_26_Feb_100003_thumb.jpg",130,176,1);thumbnails[880724]=new thumbnail(880724,"67564","Passion ","passion 97 cover_thumb.jpg",130,189,1);thumbnails[881027]=new thumbnail(881027,"67564","HAIR Magazine","HAIR - Apr-May 06_thumb.jpg",130,176,1);thumbnails[881057]=new thumbnail(881057,"67564","CREATIVE HEAD Magazine","Creative Head - April 07_thumb.jpg",130,183,1);var galleries=new Object();galleries[291712]=new gallery(291712,"5165696,5165695,5165694,5165528,5165526,4824807,4824805,4824799,4824792,4824790","2009/10 BHA winning collections","gallery",[4824754,4824757,4824758,4824762,4824790,4824805,5165526,5165694,5165695,5165696,5165528,4824775,4824807,4824788,4824792,4824799]);galleries[254087]=new gallery(254087,"5165314,5165313,4824808,4824801,4824795,4824740,4824737,4824735,4824733,4824725","2009","gallery",[4824723,4824725,4824733,4824735,4824737,4824740,4824795,4824801,4824808,5165313,5165314]);galleries[67564]=new gallery(67564,"3329079,1900952,880724","Media ","gallery",[1544233,1544237,1831227,1831234,1831254,1832903,1832904,1832906,1833804,1900952,2965418,3329079,3654540,5363235,5363236,5524345,5524364,5524365,5524369,5524370,5524371,5524375,5524378,5524379,5524381,5524382,5524383,5560647,5560649,880724,881027,881057]);var imageSets=new Object();imageSets[1]="2797209,1786259,880724";imageSets[2]="3329079,2797209,1900952,1786259,880724";imageSets[3]="5560649,5560647,5524383,5524382,5524381,5524379,5524378,5524375,5524371,5524370,5524369,5524365,5524364,5524345,5363236,5363235,5165696,5165695,5165694,5165528,5165526,5165314,5165313,4824808,4824807,4824805,4824801,4824799,4824795,4824792,4824790,4824788,4824775,4824762,4824758,4824757,4824754,4824740,4824737,4824735,4824733,4824725,4824723,3654540,3329079,3269615,3269614,3269613,2965418,2797258";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/TRP/images";break}switch(a){case 1:b="http://www1.clikpic.com/TRP/images";break}switch(a){case 2:b="http://admin.clikpic.com/TRP/images";break}switch(a){case 24:b="http://tpc15/clikpic/TRP/images";break}switch(a){case 4:b="http://www.clikchurch.com/TRP/images";break}switch(a){case 5:b="http://www2.clikpic.com/TRP/images";break}switch(a){case 22:b="http://tpc5/clikpic/TRP/images";break}switch(a){case 23:b="http://tpc10/clikpic/TRP/images";break}switch(a){case 25:b="http://tpc16/clikpic/TRP/images";break}switch(a){case 15:b="http://www3.clikpic.com/TRP/images";break}switch(a){case 18:b="http://www4.clikpic.com/TRP/images";break}switch(a){case 19:b="http://www5.clikpic.com/TRP/images";break}switch(a){case 31:b="http://www7.clikpic.com/TRP/images";break}switch(a){case 32:b="http://admin2.clikpic.com/TRP/images";break}switch(a){case 33:b="http://www8.clikpic.com/TRP/images";break}switch(a){case 34:b="http://www9.clikpic.com/TRP/images";break}switch(a){case 35:b="http://admin3.clikpic.com/TRP/images";break}switch(a){case 37:b="http://admin4.clikpic.com/TRP/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="therawsonpartnership.net: "+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({centre:true});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(b,a){imageID=randomListVal(galleries[b].featured_images);if(imageID!=0){a.src=thumbnails[imageID].src;a.width=thumbnails[imageID].width;a.height=thumbnails[imageID].height}}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+'")'})}}};