function photo(j,c,p,t,d,k,h,r,v,o,m,s,a,n,g,l,b,u,q,f,e){this.id=j;this.galleries_id=c;this.photo_ref=p;this.section_code=t;this.src=d;this.width=k;this.height=h;this.caption=r;this.thumbnail=v;this.thumbnail_width=o;this.thumbnail_height=m;this.home=s;this.gallery=a;this.description=n;this.takendate=g;this.photographer=l;this.location=b;this.item_price=u;this.purchase_instruction=q;this.payment_groups_id=f;this.server_id=e;this.src=getServerPath(this.server_id)+"/"+this.src;this.thumbnail=getServerPath(this.server_id)+"/"+this.thumbnail}function gallery(e,c,d,b,a){this.id=e;this.featured_images=c;this.title=d;this.section_code=b;this.photoIDs=a}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 photos=new Object();photos[4084796]=new photo(4084796,"255001","","section308055","photos_14.gif",100,75,"","photos_14_thumb.gif",130,98,1,0,"","","","","","","",15);photos[4084831]=new photo(4084831,"255001","","section308055","photos_16.gif",100,80,"","photos_16_thumb.gif",130,104,0,0,"","","","","","","",15);photos[4084834]=new photo(4084834,"255001","","section308055","photos_18.gif",99,80,"Bedroom 2","photos_18_thumb.gif",130,105,0,0,"","","","","","","",15);photos[4084837]=new photo(4084837,"255001","","section308055","photos_23.gif",100,80,"Master Bedroom","photos_23_thumb.gif",130,104,0,0,"","","","","","","",15);photos[4084871]=new photo(4084871,"255001","","section308055","Master_Bedroom.jpg",200,160,"Master Bedroom","Master_Bedroom_thumb.jpg",130,104,0,0,"","","","","","","",15);photos[4084874]=new photo(4084874,"255001","","section308055","PICT0024.jpg",200,160,"Open plan Lounge / Kitchen","PICT0024_thumb.jpg",130,104,0,0,"","","","","","","",15);photos[4084876]=new photo(4084876,"255001","","section308055","PICT0030.jpg",200,160,"Open plan Lounge / Kitchen","PICT0030_thumb.jpg",130,104,0,0,"","","","","","","",15);photos[4084877]=new photo(4084877,"255001","","section308055","PICT0034.jpg",200,160,"Open plan Lounge / Kitchen","PICT0034_thumb.jpg",130,104,0,0,"","","","","","","",15);photos[4084880]=new photo(4084880,"","","","PICT0033.jpg",200,160,"Formal Sitting / Dining Area","PICT0033_thumb.jpg",130,104,0,0,"","","","","","","",15);photos[4084881]=new photo(4084881,"","","","PICT0036.jpg",200,160,"Formal Sitting / Dining Area","PICT0036_thumb.jpg",130,104,0,0,"","","","","","","",15);photos[4084886]=new photo(4084886,"255001","","section308055","PICT0109.jpg",200,160,"Pool Area","PICT0109_thumb.jpg",130,104,0,0,"","","","","","","",15);photos[4084888]=new photo(4084888,"255001","","section308055","Pool.jpg",200,160,"Pool Area","Pool_thumb.jpg",130,104,0,0,"","","","","","","",15);photos[4084900]=new photo(4084900,"255001","","section308055","Twin_Bedroom.jpg",200,160,"Bedroom 3","Twin_Bedroom_thumb.jpg",130,104,0,0,"","","","","","","",15);photos[4085101]=new photo(4085101,"255001","","section308055","PoolAreaResize.jpg",500,375,"Pool Area","PoolAreaResize_thumb.jpg",130,98,0,0,"","","","","","","",15);photos[4085221]=new photo(4085221,"","","","disney-world2.jpg",333,400,"Walt Disney World","disney-world2_thumb.jpg",130,156,0,0,"","","","","","","",15);photos[4085228]=new photo(4085228,"","","","animal-kingdom.gif",261,250,"Animal Kingdom","animal-kingdom_thumb.gif",130,125,0,0,"","","","","","","",15);photos[4085230]=new photo(4085230,"","","","discoverycove.jpg",239,167,"Discovery Cove","discoverycove_thumb.jpg",130,91,0,0,"","","","","","","",15);photos[4085232]=new photo(4085232,"","","","Sea_World.jpg",300,300,"Sea World","Sea_World_thumb.jpg",130,130,0,0,"","","","","","","",15);photos[4085235]=new photo(4085235,"","","","islands_of_adventure.jpg",204,204,"Islands Of Adventure","islands_of_adventure_thumb.jpg",130,130,0,0,"","","","","","","",15);photos[4085236]=new photo(4085236,"","","","universal_studios.jpg",252,166,"Universal Studios","universal_studios_thumb.jpg",130,86,0,0,"","","","","","","",15);photos[4085238]=new photo(4085238,"","","","space_center.jpg",320,240,"Kennedy Space Centre","space_center_thumb.jpg",130,98,0,0,"","","","","","","",15);photos[4085241]=new photo(4085241,"","","","Gatorland.jpg",200,133,"Gatorland","Gatorland_thumb.jpg",130,86,0,0,"","","","","","","",15);photos[4085242]=new photo(4085242,"","","","bush_gardens.jpg",209,179,"Busch Gardens","bush_gardens_thumb.jpg",130,111,0,0,"","","","","","","",15);photos[4359340]=new photo(4359340,"256185","","section308055","PoolArea1resize.jpg",500,375,"Pool Area","PoolArea1resize_thumb.jpg",130,98,0,0,"","","","","","","",2);photos[4359343]=new photo(4359343,"256185","","section308055","SwimmingPoolresize.jpg",500,375,"Swimming Pool","SwimmingPoolresize_thumb.jpg",130,98,0,0,"","","","","","","",2);photos[4359316]=new photo(4359316,"256185","","section308055","FormalLivingresize.jpg",500,375,"Formal Sitting Area","FormalLivingresize_thumb.jpg",130,98,0,0,"","","","","","","",2);photos[4359315]=new photo(4359315,"256185","","section308055","DiningArea1resize.jpg",500,375,"Formal Dining Area","DiningArea1resize_thumb.jpg",130,98,0,0,"","","","","","","",2);photos[4359333]=new photo(4359333,"256185","","section308055","LivingArearesize.jpg",500,375,"Sitting Area","LivingArearesize_thumb.jpg",130,98,0,0,"","","","","","","",2);photos[4359319]=new photo(4359319,"256185","","section308055","Kitchen1resize.jpg",500,375,"Kitchen Area","Kitchen1resize_thumb.jpg",130,98,0,0,"","","","","","","",2);photos[4359336]=new photo(4359336,"256185","","section308055","MasterBed1resize.jpg",500,375,"Master Bedroom","MasterBed1resize_thumb.jpg",130,98,0,0,"","","","","","","",2);photos[4359304]=new photo(4359304,"256185","","section308055","Bedroom2resize.jpg",500,375,"Double Bedroom 2","Bedroom2resize_thumb.jpg",130,98,0,0,"","","","","","","",2);photos[4359314]=new photo(4359314,"256185","","section308055","Bedroom3reszie.jpg",500,375,"Twin Bedroom 3","Bedroom3reszie_thumb.jpg",130,98,0,0,"","","","","","","",2);photos[4359317]=new photo(4359317,"256185","","section308055","Garden1resize.jpg",500,375,"Garden","Garden1resize_thumb.jpg",130,98,0,0,"","","","","","","",2);var thumbnails=new Object();thumbnails[4084796]=new thumbnail(4084796,"255001","","photos_14_thumb.gif",130,98,15);thumbnails[4084831]=new thumbnail(4084831,"255001","","photos_16_thumb.gif",130,104,15);thumbnails[4084834]=new thumbnail(4084834,"255001","Bedroom 2","photos_18_thumb.gif",130,105,15);thumbnails[4084837]=new thumbnail(4084837,"255001","Master Bedroom","photos_23_thumb.gif",130,104,15);thumbnails[4084871]=new thumbnail(4084871,"255001","Master Bedroom","Master_Bedroom_thumb.jpg",130,104,15);thumbnails[4084874]=new thumbnail(4084874,"255001","Open plan Lounge / Kitchen","PICT0024_thumb.jpg",130,104,15);thumbnails[4084876]=new thumbnail(4084876,"255001","Open plan Lounge / Kitchen","PICT0030_thumb.jpg",130,104,15);thumbnails[4084877]=new thumbnail(4084877,"255001","Open plan Lounge / Kitchen","PICT0034_thumb.jpg",130,104,15);thumbnails[4084880]=new thumbnail(4084880,"","Formal Sitting / Dining Area","PICT0033_thumb.jpg",130,104,15);thumbnails[4084881]=new thumbnail(4084881,"","Formal Sitting / Dining Area","PICT0036_thumb.jpg",130,104,15);thumbnails[4084886]=new thumbnail(4084886,"255001","Pool Area","PICT0109_thumb.jpg",130,104,15);thumbnails[4084888]=new thumbnail(4084888,"255001","Pool Area","Pool_thumb.jpg",130,104,15);thumbnails[4084900]=new thumbnail(4084900,"255001","Bedroom 3","Twin_Bedroom_thumb.jpg",130,104,15);thumbnails[4085101]=new thumbnail(4085101,"255001","Pool Area","PoolAreaResize_thumb.jpg",130,98,15);thumbnails[4085221]=new thumbnail(4085221,"","Walt Disney World","disney-world2_thumb.jpg",130,156,15);thumbnails[4085228]=new thumbnail(4085228,"","Animal Kingdom","animal-kingdom_thumb.gif",130,125,15);thumbnails[4085230]=new thumbnail(4085230,"","Discovery Cove","discoverycove_thumb.jpg",130,91,15);thumbnails[4085232]=new thumbnail(4085232,"","Sea World","Sea_World_thumb.jpg",130,130,15);thumbnails[4085235]=new thumbnail(4085235,"","Islands Of Adventure","islands_of_adventure_thumb.jpg",130,130,15);thumbnails[4085236]=new thumbnail(4085236,"","Universal Studios","universal_studios_thumb.jpg",130,86,15);thumbnails[4085238]=new thumbnail(4085238,"","Kennedy Space Centre","space_center_thumb.jpg",130,98,15);thumbnails[4085241]=new thumbnail(4085241,"","Gatorland","Gatorland_thumb.jpg",130,86,15);thumbnails[4085242]=new thumbnail(4085242,"","Busch Gardens","bush_gardens_thumb.jpg",130,111,15);thumbnails[4359340]=new thumbnail(4359340,"256185","Pool Area","PoolArea1resize_thumb.jpg",130,98,2);thumbnails[4359343]=new thumbnail(4359343,"256185","Swimming Pool","SwimmingPoolresize_thumb.jpg",130,98,2);thumbnails[4359316]=new thumbnail(4359316,"256185","Formal Sitting Area","FormalLivingresize_thumb.jpg",130,98,2);thumbnails[4359315]=new thumbnail(4359315,"256185","Formal Dining Area","DiningArea1resize_thumb.jpg",130,98,2);thumbnails[4359333]=new thumbnail(4359333,"256185","Sitting Area","LivingArearesize_thumb.jpg",130,98,2);thumbnails[4359319]=new thumbnail(4359319,"256185","Kitchen Area","Kitchen1resize_thumb.jpg",130,98,2);thumbnails[4359336]=new thumbnail(4359336,"256185","Master Bedroom","MasterBed1resize_thumb.jpg",130,98,2);thumbnails[4359304]=new thumbnail(4359304,"256185","Double Bedroom 2","Bedroom2resize_thumb.jpg",130,98,2);thumbnails[4359314]=new thumbnail(4359314,"256185","Twin Bedroom 3","Bedroom3reszie_thumb.jpg",130,98,2);thumbnails[4359317]=new thumbnail(4359317,"256185","Garden","Garden1resize_thumb.jpg",130,98,2);var galleries=new Object();galleries[255001]=new gallery(255001,"4085101,4084900,4084888,4084886,4084877,4084876,4084874,4084871,4084837,4084834","G1","section308055",[4084796,4084831,4084834,4084837,4084871,4084874,4084876,4084877,4084886,4084888,4084900,4085101]);galleries[256185]=new gallery(256185,"4359343,4359340,4359336,4359333,4359319,4359317,4359316,4359315,4359314,4359304","G2","section308055",[4359340,4359343,4359316,4359315,4359333,4359319,4359336,4359304,4359314,4359317]);var imageSets=new Object();imageSets[1]="4359343,4359340,4359336,4359333,4359319,4359317,4359316,4359315,4359314,4359304,4084796";imageSets[3]="4084886,4084831";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 1:b="http://www1.clikpic.com/Storm28/images";break}switch(a){case 2:b="http://admin.clikpic.com/Storm28/images";break}switch(a){case 4:b="http://www.clikchurch.com/Storm28/images";break}switch(a){case 5:b="http://www2.clikpic.com/Storm28/images";break}switch(a){case 15:b="http://www3.clikpic.com/Storm28/images";break}switch(a){case 21:b="http://www6.clikpic.com/Storm28/images";break}switch(a){case 18:b="http://www4.clikpic.com/Storm28/images";break}switch(a){case 19:b="http://www5.clikpic.com/Storm28/images";break}switch(a){case 22:b="http://tpc5/clikpic/Storm28/images";break}switch(a){case 23:b="http://tpc10/clikpic/Storm28/images";break}switch(a){case 24:b="http://tpc15/clikpic/Storm28/images";break}switch(a){case 25:b="http://tpc16/clikpic/Storm28/images";break}switch(a){case 31:b="http://www7.clikpic.com/Storm28/images";break}switch(a){case 32:b="http://admin2.clikpic.com/Storm28/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("section308055"!=""){if(photos[imageID].galleries_id!=""){html+='<a href="'+photos[imageID].section_code+"_"+photos[imageID].galleries_id+'.html">'}else{html+='<a href="section308055.html">'}}html+='<img src="'+photos[imageID].src+'" width="'+photos[imageID].width+'" height="'+photos[imageID].height+'" class="mainhomepageimage photo" id="mainSample" name="mainSample" alt="'+photos[imageID].caption+'" border="0">';if("section308055"!=""){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="Cypress Lakes Villa - Luxury 3 Bedroom Villa: "+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(){if(addItemToBasket(document.getElementById("paymentForm"))){if($.browser.msie){$("#paymentConfirm").show()}else{$("#paymentConfirm").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+"</p>";var e=c.purchase_instruction;var d=c.item_price;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=photos[c].src;var b=$(a);if(b.size()>0){if(/\bimg$/.test(a)){b.attr({src:d})}else{b.css({"background-image":'url("'+d+'")'})}}};