if(document.all&&!document.getElementById){document.getElementById=function(id){return document.all[id];}}
var buttonState="button5";var UK_VAT=1.2;function button_over(buttonID,cellID,imgURL)
{cellID.style.cursor='pointer';if(buttonID=="button4"){cellID.style.backgroundImage='url(../images/feature-menu-wide-over.png)';}else{cellID.style.backgroundImage='url(../images/feature-menu-over.png)';}
document.getElementById(buttonID).style.backgroundPosition=imgURL;cellID.style.color='#333333';}
function button_out(buttonID,cellID,imgURL)
{if(buttonID!=buttonState)
{if(buttonID=="button4"){cellID.style.backgroundImage='url(../images/feature-menu-wide-off.png)';}else{cellID.style.backgroundImage='url(../images/feature-menu-off.png)';}
document.getElementById(buttonID).style.backgroundPosition=imgURL;cellID.style.color='#FFFFFF';}}
function button_click(buttonID,id)
{var featboxes=['freedel','twoyearguarantee','pricewatch','homeview','installation'];var boxnum=featboxes.length;for(var i=0,len=boxnum;i<len;++i)
{allID=featboxes[i];document.getElementById(allID).style.display='none';}
if(document.getElementById(id).style.display=="none")
{document.getElementById(id).style.display='block';}
buttonState=buttonID;if(buttonID!="button1"){document.getElementById('feat_img1').style.backgroundImage='url(../images/feature-menu-off.png)';document.getElementById('feat_img1').style.color='#FFFFFF';document.getElementById('button1').style.backgroundPosition="-258px -12px";}
if(buttonID!="button2"){document.getElementById('feat_img2').style.backgroundImage='url(../images/feature-menu-off.png)';document.getElementById('feat_img2').style.color='#FFFFFF';document.getElementById('button2').style.backgroundPosition="-184px -12px";}
if(buttonID!="button3"){document.getElementById('feat_img3').style.backgroundImage='url(../images/feature-menu-off.png)';document.getElementById('feat_img3').style.color='#FFFFFF';document.getElementById('button3').style.backgroundPosition="-199px -12px";}
if(buttonID!="button4"){document.getElementById('feat_img4').style.backgroundImage='url(../images/feature-menu-wide-off.png)';document.getElementById('feat_img4').style.color='#FFFFFF';document.getElementById('button4').style.backgroundPosition="-217px -11px";}
if(buttonID!="button5"){document.getElementById('feat_img5').style.backgroundImage='url(../images/feature-menu-off.png)';document.getElementById('feat_img5').style.color='#FFFFFF';document.getElementById('button5').style.backgroundPosition="-238px -12px";}}
function DVOver(obj)
{obj.style.cursor='pointer';obj.style.borderColor='#FF0000';}
function DVOff(obj)
{obj.style.borderColor='#FFFFFF';}
function DVOff2(obj)
{obj.style.borderColor='#848484';}
function show(id,id2)
{var views=['front','left','right','top','open'];var txt=['txt1','txt2','txt3','txt4','txt5'];var medialen=views.length;var txtlen=txt.length;for(var i=0,len=medialen;i<len;++i)
{allID=views[i];allID2=txt[i];document.getElementById(allID).style.display='none';document.getElementById(allID2).style.color='white';document.getElementById(allID2).style.backgroundColor='#3B3B3B';}
if(document.getElementById(id).style.display=="none"){document.getElementById(id).style.display='block';}
if(document.getElementById(id2).style.color=="white"){document.getElementById(id2).style.color='black';document.getElementById(id2).style.backgroundColor='#E9E9E9';}}
function fieldheaders(status,field)
{if(status=="focus")
{if((field=="name")&&(document.getElementById(field).value=="Name"))document.getElementById(field).value="";if((field=="email")&&(document.getElementById(field).value=="Email"))document.getElementById(field).value="";if((field=="phone")&&(document.getElementById(field).value=="Phone Number"))document.getElementById(field).value="";if((field=="question")&&(document.getElementById(field).value=="Your Question"))document.getElementById(field).value="";}
if(status=="blur")
{if((field=="name")&&(document.getElementById(field).value==""))document.getElementById(field).value="Name";if((field=="email")&&(document.getElementById(field).value==""))document.getElementById(field).value="Email";if((field=="phone")&&(document.getElementById(field).value==""))document.getElementById(field).value="Phone Number";if((field=="question")&&(document.getElementById(field).value==""))document.getElementById(field).value="Your Question";}}
function loadimg(filename,widthvar,heightvar){window.open(filename,'imgwindow',config='height='+heightvar+',width='+widthvar+', toolbar=no, menubar=no, scrollbars=yes, resizable=no, location=no, directories=no, status=no');}
function printWebpage()
{window.print();return false;}
function AddtoFavourites()
{if(/Firefox[\/\s](\d+\.\d+)/.test(navigator.userAgent))
{window.sidebar.addPanel('Di Vapor Steam, Sauna & Hydromassage','http://www.divapor.com','');}
else if(/Chrome[\/\s](\d+\.\d+)/.test(navigator.userAgent))
{alert("Please press 'Ctrl+D' on your keyboard to bookmark this webpage in Chrome.");}
else if(/Opera[\/\s](\d+\.\d+)/.test(navigator.userAgent))
{alert("Please press 'Ctrl+D' on your keyboard to bookmark this webpage in Opera.");}
else if(/MSIE (\d+\.\d+);/.test(navigator.userAgent))
{window.external.AddFavorite('http://www.divapor.com','Di Vapor Steam, Sauna & Hydromassage');}
else
{alert("Please press 'Ctrl+D' on your keyboard to bookmark this webpage.");}
return false;}
function addtocart(action,productID,pagepos)
{var extras="";if((pagepos=="top")||(pagepos=="bottom"))extras="&extras=";if((pagepos=="top")&&(typeof document.genform!='undefined'))
{if((typeof document.genform.oils!='undefined')&&(document.genform.oils.checked))extras+="A-DV006";if((typeof document.genform.ct1!='undefined')&&(document.genform.ct1.checked))extras+=",A-DVCT1W";if((typeof document.genform.purespa!='undefined')&&(document.genform.purespa.checked))extras+=",A-DVPSSP";}
if((pagepos=="bottom")&&(typeof document.genform2!='undefined'))
{if((typeof document.genform2.oils_2!='undefined')&&(document.genform2.oils_2.checked))extras+="A-DV006";if((typeof document.genform2.ct1_2!='undefined')&&(document.genform2.ct1_2.checked))extras+=",A-DVCT1W";if((typeof document.genform2.purespa_2!='undefined')&&(document.genform2.purespa_2.checked))extras+=",A-DVPSSP";}
if(action=="add")location.href="/cart.php?action=add&id="+productID+extras;else if(action=="add_dep")location.href="/cart.php?action=add_dep&id="+productID+extras;}
function formatCurrency(strValue)
{strValue=strValue.toString().replace(/\$|\,/g,'');dblValue=parseFloat(strValue);blnSign=(dblValue==(dblValue=Math.abs(dblValue)));dblValue=Math.floor(dblValue*100+0.50000000001);intCents=dblValue%100;strCents=intCents.toString();dblValue=Math.floor(dblValue/100).toString();if(intCents<10)
strCents="0"+strCents;for(var i=0;i<Math.floor((dblValue.length-(1+i))/3);i++)
dblValue=dblValue.substring(0,dblValue.length-(4*i+3))+','+
dblValue.substring(dblValue.length-(4*i+3));return(((blnSign)?'':'-')+dblValue+'.'+strCents);}
function removeCommas(aNum)
{aNum=aNum.replace(/,/g,"");aNum=aNum.replace(/\s/g,"");return aNum;}
function updatePrice(checkboxID,amount,pagepos)
{var curr_amount=removeCommas(document.getElementById('pricetext').innerHTML);if(pagepos=="top"){var boxname=checkboxID.name+"_2";}else{var boxname=checkboxID.name.substr(0,checkboxID.name.length-2);}
if(checkboxID.checked){var new_total=parseFloat(curr_amount)+parseFloat(amount);document.getElementById(boxname).checked=true;}else
{var new_total=parseFloat(curr_amount)-parseFloat(amount);document.getElementById(boxname).checked=false;}
document.getElementById('pricetext').innerHTML=formatCurrency(new_total);document.getElementById('pricetext2').innerHTML=formatCurrency(new_total);document.getElementById('pricetextRRP').innerHTML=formatCurrency(new_total*UK_VAT);document.getElementById('pricetext2RRP').innerHTML=formatCurrency(new_total*UK_VAT);document.getElementById('pricetext10pc').innerHTML=formatCurrency(new_total/10);document.getElementById('pricetext10pc2').innerHTML=formatCurrency(new_total/10);}
function submitDeposit(radioObj,rad_opt)
{if(!radioObj)
return;var radioLength=radioObj.length;if(radioLength==undefined){radioObj.checked=(radioObj.value==rad_opt.toString());return;}
for(var i=0;i<radioLength;i++){radioObj[i].checked=false;if(radioObj[i].value==rad_opt.toString()){radioObj[i].checked=true;}}
document.forms.cart.submit();}
var cX=0;var cY=0;var rX=0;var rY=0;function UpdateCursorPosition(e){cX=e.pageX;cY=e.pageY;}
function UpdateCursorPositionDocAll(e){cX=event.clientX;cY=event.clientY;}
if(document.all){document.onmousemove=UpdateCursorPositionDocAll;}
else{document.onmousemove=UpdateCursorPosition;}
function AssignPosition(d){if(self.pageYOffset){rX=self.pageXOffset;rY=self.pageYOffset;}
else if(document.documentElement&&document.documentElement.scrollTop){rX=document.documentElement.scrollLeft;rY=document.documentElement.scrollTop;}
else if(document.body){rX=document.body.scrollLeft;rY=document.body.scrollTop;}
if(document.all){cX+=rX;cY+=rY;}
d.style.left=(cX+10)+"px";d.style.top=(cY+10)+"px";}
function HideContent(d){if(d.length<1){return;}
document.getElementById(d).style.display="none";}
function ShowContent(d){if(d.length<1){return;}
var dd=document.getElementById(d);AssignPosition(dd);dd.style.display="block";}
function ReverseContentDisplay(d){if(d.length<1){return;}
var dd=document.getElementById(d);AssignPosition(dd);if(dd.style.display=="none"){dd.style.display="block";}
else{dd.style.display="none";}}
String.prototype.trim=function()
{return this.replace(/^[\s]+|[\s]+$/,"");};function SuggestFramework_Create(instance)
{if(SuggestFramework_Name[instance]&&SuggestFramework_Action[instance])
{SuggestFramework_InputContainer[instance]=document.getElementById(SuggestFramework_Name[instance]);SuggestFramework_InputContainer[instance].autocomplete="off";SuggestFramework_InputContainer[instance].onblur=function(){SuggestFramework_HideOutput(instance);};SuggestFramework_InputContainer[instance].onclick=function(){SuggestFramework_ShowOutput(instance);SuggestFramework_Previous[instance]='';};SuggestFramework_InputContainer[instance].onfocus=function(){SuggestFramework_ShowOutput(instance);};SuggestFramework_InputContainer[instance].onkeydown=function(event){SuggestFramework_ProcessKeys(instance,event);};SuggestFramework_OutputContainer[instance]=document.createElement("div");SuggestFramework_OutputContainer[instance].id=SuggestFramework_Name[instance]+"SuggestList";SuggestFramework_OutputContainer[instance].className="SuggestFramework_List";SuggestFramework_OutputContainer[instance].style.position="absolute";SuggestFramework_OutputContainer[instance].style.zIndex="1";SuggestFramework_OutputContainer[instance].style.width=SuggestFramework_InputContainer[instance].clientWidth+"px";SuggestFramework_OutputContainer[instance].style.wordWrap="break-word";SuggestFramework_OutputContainer[instance].style.cursor="default";SuggestFramework_InputContainer[instance].parentNode.insertBefore(SuggestFramework_OutputContainer[instance],SuggestFramework_InputContainer[instance].nextSibling);SuggestFramework_InputContainer[instance].parentNode.insertBefore(document.createElement("br"),SuggestFramework_OutputContainer[instance]);if(!SuggestFramework_CreateConnection())
{SuggestFramework_Proxy[instance]=document.createElement("iframe");SuggestFramework_Proxy[instance].id="proxy";SuggestFramework_Proxy[instance].style.width="0";SuggestFramework_Proxy[instance].style.height="0";SuggestFramework_Proxy[instance].style.display="none";document.body.appendChild(SuggestFramework_Proxy[instance]);if(window.frames&&window.frames["proxy"])
SuggestFramework_Proxy[instance]=window.frames["proxy"];else if(document.getElementById("proxy").contentWindow)
SuggestFramework_Proxy[instance]=document.getElementById("proxy").contentWindow;else
SuggestFramework_Proxy[instance]=document.getElementById("proxy");}
SuggestFramework_Previous[instance]=SuggestFramework_InputContainer[instance].value;SuggestFramework_HideOutput(instance);SuggestFramework_Throttle(instance);}
else
{throw'Error: SuggestFramework for instance "'+SuggestFramework_Name[instance]+'" not initialized';}};function SuggestFramework_CreateConnection()
{var asynchronousConnection;try
{asynchronousConnection=new ActiveXObject("Microsoft.XMLHTTP");}
catch(e)
{if(typeof(XMLHttpRequest)!="undefined")
asynchronousConnection=new XMLHttpRequest();}
return asynchronousConnection;};function SuggestFramework_HideOutput(instance)
{SuggestFramework_OutputContainer[instance].style.display="none";};function SuggestFramework_Highlight(instance,index)
{SuggestFramework_SuggestionsIndex[instance]=index;for(var i in SuggestFramework_Suggestions[instance])
{var suggestColumns=document.getElementById(SuggestFramework_Name[instance]+"Suggestions["+i+"]").getElementsByTagName("td");for(var j in suggestColumns)
suggestColumns[j].className="SuggestFramework_Normal";}
var suggestColumns=document.getElementById(SuggestFramework_Name[instance]+"Suggestions["+SuggestFramework_SuggestionsIndex[instance]+"]").getElementsByTagName("td");for(var i in suggestColumns)
suggestColumns[i].className="SuggestFramework_Highlighted";};function SuggestFramework_IsHidden(instance)
{return((SuggestFramework_OutputContainer[instance].style.display=="none")?true:false);};function SuggestFramework_ProcessKeys(instance,e)
{var keyDown=40;var keyUp=38;var keyTab=9;var keyEnter=13;var keyEscape=27;var keyPressed=((window.event)?window.event.keyCode:e.which);if(!SuggestFramework_IsHidden(instance))
{switch(keyPressed)
{case keyDown:SuggestFramework_SelectNext(instance);return;case keyUp:SuggestFramework_SelectPrevious(instance);return;case keyTab:SuggestFramework_SelectThis(instance);return;case keyEnter:SuggestFramework_SelectThis(instance);return;case keyEscape:SuggestFramework_HideOutput(instance);return;default:return;}}};function SuggestFramework_ProcessProxyRequest(instance)
{var result=((SuggestFramework_Proxy[instance].document)?SuggestFramework_Proxy[instance].document:SuggestFramework_Proxy[instance].contentDocument);result=result.body.innerHTML.replace(/\r|\n/g," ").trim();if(typeof(eval(result))=="object")
SuggestFramework_Suggest(instance,eval(result));else
setTimeout("SuggestFramework_ProcessProxyRequest("+instance+")",100);};function SuggestFramework_ProcessRequest(instance)
{if(SuggestFramework_Connection[instance].readyState==4)
{if(SuggestFramework_Connection[instance].status==200){SuggestFramework_Suggest(instance,eval(SuggestFramework_Connection[instance].responseText));}}};function SuggestFramework_Query(instance)
{SuggestFramework_Throttle(instance);var phrase=SuggestFramework_InputContainer[instance].value;if(phrase==""||phrase==SuggestFramework_Previous[instance])return;SuggestFramework_Previous[instance]=phrase;phrase=phrase.trim();phrase=escape(phrase);SuggestFramework_Request(instance,SuggestFramework_Action[instance]+"?type="+SuggestFramework_Name[instance]+"&q="+phrase);};function SuggestFramework_Request(instance,url)
{if(SuggestFramework_Connection[instance]=SuggestFramework_CreateConnection())
{SuggestFramework_Connection[instance].onreadystatechange=function(){SuggestFramework_ProcessRequest(instance)};SuggestFramework_Connection[instance].open("GET",url,true);SuggestFramework_Connection[instance].send(null);}
else
{SuggestFramework_Proxy[instance].location.replace(url);SuggestFramework_ProcessProxyRequest(instance);}};function SuggestFramework_SelectThis(instance,index)
{if(!isNaN(index))
SuggestFramework_SuggestionsIndex[instance]=index;if(SuggestFramework_Columns[instance]>1)
SuggestFramework_InputContainer[instance].value=SuggestFramework_Suggestions[instance][SuggestFramework_SuggestionsIndex[instance]][SuggestFramework_Capture[instance]-1];else
SuggestFramework_InputContainer[instance].value=SuggestFramework_Suggestions[instance][SuggestFramework_SuggestionsIndex[instance]];SuggestFramework_Previous[instance]=SuggestFramework_InputContainer[instance].value;SuggestFramework_HideOutput(instance);document.forms["searchform"].submit();};function SuggestFramework_SelectNext(instance)
{SuggestFramework_SetTextSelectionRange(instance);if(typeof(SuggestFramework_Suggestions[instance][(SuggestFramework_SuggestionsIndex[instance]+1)])!="undefined")
{if(typeof(SuggestFramework_Suggestions[instance][SuggestFramework_SuggestionsIndex[instance]])!="undefined")
document.getElementById(SuggestFramework_Name[instance]+"Suggestions["+SuggestFramework_SuggestionsIndex[instance]+"]").className="SuggestFramework_Normal";SuggestFramework_SuggestionsIndex[instance]++;SuggestFramework_Highlight(instance,SuggestFramework_SuggestionsIndex[instance]);}};function SuggestFramework_SelectPrevious(instance)
{SuggestFramework_SetTextSelectionRange(instance);if(typeof(SuggestFramework_Suggestions[instance][(SuggestFramework_SuggestionsIndex[instance]-1)])!="undefined")
{if(typeof(SuggestFramework_Suggestions[instance][SuggestFramework_SuggestionsIndex[instance]])!="undefined")
document.getElementById(SuggestFramework_Name[instance]+"Suggestions["+SuggestFramework_SuggestionsIndex[instance]+"]").className="SuggestFramework_Normal";SuggestFramework_SuggestionsIndex[instance]--;SuggestFramework_Highlight(instance,SuggestFramework_SuggestionsIndex[instance]);}};function SuggestFramework_SetTextSelectionRange(instance,start,end)
{if(!start)var start=SuggestFramework_InputContainer[instance].value.length;if(!end)var end=SuggestFramework_InputContainer[instance].value.length;if(SuggestFramework_InputContainer[instance].setSelectionRange)
{SuggestFramework_InputContainer[instance].setSelectionRange(start,end);}
else if(SuggestFramework_InputContainer[instance].createTextRange)
{var selection=SuggestFramework_InputContainer[instance].createTextRange();selection.moveStart("character",start);selection.moveEnd("character",end);selection.select();}};function SuggestFramework_ShowOutput(instance)
{if(typeof(SuggestFramework_Suggestions[instance])!="undefined"&&SuggestFramework_Suggestions[instance].length)
SuggestFramework_OutputContainer[instance].style.display="block";};function SuggestFramework_Suggest(instance,list)
{SuggestFramework_Suggestions[instance]=list;SuggestFramework_SuggestionsIndex[instance]=-1;SuggestFramework_OutputContainer[instance].innerHTML="";var table='<table class="SuggestFramework_Combo" cellspacing="0" cellpadding="0">';if(SuggestFramework_Heading[instance]&&SuggestFramework_Suggestions[instance].length)
{var heading=SuggestFramework_Suggestions[instance].shift();var thead='<thead>';var headingContainer='<tr>';for(var i=0;i<SuggestFramework_Columns[instance];i++)
{var value=((SuggestFramework_Columns[instance]>1)?heading[i]:heading);var column='<td class="SuggestFramework_Heading"';if(SuggestFramework_Columns[instance]>1&&i==SuggestFramework_Columns[instance]-1)
column+=' style="text-align: right"';column+='>'+value.trim()+'</td>';headingContainer+=column;}
headingContainer+='</tr>';thead+=headingContainer;thead+='</thead>';table+=thead;}
var tbody='<tbody>';for(var i in SuggestFramework_Suggestions[instance])
{var suggestionContainer='<tr id="'+SuggestFramework_Name[instance]+'Suggestions['+i+']">';for(var j=0;j<SuggestFramework_Columns[instance];j++)
{var value=((SuggestFramework_Columns[instance]>1)?SuggestFramework_Suggestions[instance][i][j]:SuggestFramework_Suggestions[instance][i]);var column='<td class="SuggestFramework_Normal"';if(SuggestFramework_Columns[instance]>1&&j==SuggestFramework_Columns[instance]-1)
column+=' style="text-align: right"';column+='>'+value.trim()+'</td>';suggestionContainer+=column;}
suggestionContainer+='</tr>';table+=suggestionContainer;}
tbody+='</tbody>';table+=tbody;table+='</table>';SuggestFramework_OutputContainer[instance].innerHTML=table;for(var i in SuggestFramework_Suggestions[instance])
{var row=document.getElementById(SuggestFramework_Name[instance]+'Suggestions['+i+']');row.onmouseover=new Function("SuggestFramework_Highlight("+instance+", "+i+")");row.onmousedown=new Function("SuggestFramework_SelectThis("+instance+", "+i+")");}
SuggestFramework_ShowOutput(instance);};function SuggestFramework_Throttle(instance)
{setTimeout("SuggestFramework_Query("+instance+")",SuggestFramework_Delay[instance]);};function initializeSuggestFramework()
{function getAttributeByName(node,attributeName)
{if(typeof(NamedNodeMap)!="undefined")
{if(node.attributes.getNamedItem(attributeName))
return node.attributes.getNamedItem(attributeName).value;}
else
{return node.getAttribute(attributeName);}}
var inputElements=document.getElementsByTagName("input");try
{for(var instance=0;instance<inputElements.length;instance++)
{if(getAttributeByName(inputElements[instance],"name")&&getAttributeByName(inputElements[instance],"type")=="text"&&getAttributeByName(inputElements[instance],"action"))
{SuggestFramework_Action[instance]=getAttributeByName(inputElements[instance],"action");SuggestFramework_Capture[instance]=1;SuggestFramework_Columns[instance]=1;SuggestFramework_Delay[instance]=1000;SuggestFramework_Heading[instance]=false;SuggestFramework_Name[instance]=getAttributeByName(inputElements[instance],"name");if(getAttributeByName(inputElements[instance],"capture"))
SuggestFramework_Capture[instance]=getAttributeByName(inputElements[instance],"capture");if(getAttributeByName(inputElements[instance],"columns"))
SuggestFramework_Columns[instance]=getAttributeByName(inputElements[instance],"columns");if(getAttributeByName(inputElements[instance],"delay"))
SuggestFramework_Delay[instance]=getAttributeByName(inputElements[instance],"delay");if(getAttributeByName(inputElements[instance],"heading"))
SuggestFramework_Heading[instance]=getAttributeByName(inputElements[instance],"heading");SuggestFramework_Create(instance);}}}
catch(e){}};var SuggestFramework_Action=new Array();var SuggestFramework_Capture=new Array();var SuggestFramework_Columns=new Array();var SuggestFramework_Delay=new Array();var SuggestFramework_Heading=new Array();var SuggestFramework_Name=new Array();var SuggestFramework_Connection=new Array();var SuggestFramework_InputContainer=new Array();var SuggestFramework_OutputContainer=new Array();var SuggestFramework_Previous=new Array();var SuggestFramework_Proxy=new Array();var SuggestFramework_Suggestions=new Array();var SuggestFramework_SuggestionsIndex=new Array();window.onload=initializeSuggestFramework;(function(){var s=document.createElement('SCRIPT'),s1=document.getElementsByTagName('SCRIPT')[0];s.type='text/javascript';s.async=true;s.src='http://widgets.digg.com/buttons.js';s1.parentNode.insertBefore(s,s1);})();(function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0];if(d.getElementById(id)){return;}
js=d.createElement(s);js.id=id;js.src="//connect.facebook.net/en_US/all.js#xfbml=1";fjs.parentNode.insertBefore(js,fjs);}(document,'script','facebook-jssdk'));(function(){var po=document.createElement('script');po.type='text/javascript';po.async=true;po.src='https://apis.google.com/js/plusone.js';var s=document.getElementsByTagName('script')[0];s.parentNode.insertBefore(po,s);})();;function preloadctrl(im){if(typeof im=='string'){var imo=new Image();imo.src=im;}}
if(document.images&&typeof preload_ctrl_images!='undefined'&&preload_ctrl_images){var ctrlimgs=[previmg,stopimg,playimg,nextimg]
for(var i_tem=0;i_tem<ctrlimgs.length;i_tem++)
if(ctrlimgs[i_tem])
preloadctrl(ctrlimgs[i_tem])}
var iss=[];function inter_slide(){if(!document.images||arguments.length==0)
return;var imgs=arguments[0];var width=null,height=null,delay=null;if(arguments.length==2)
delay=arguments[1];else if(arguments.length==3||arguments.length==4)
width=arguments[1],height=arguments[2],delay=arguments[3]?arguments[3]:null;this.dom=(document.getElementById)
this.da=document.all
this.delay=imgs.delay?imgs.delay:delay?delay:3000+iss.length*750;this.nextimgidx=0;iss[this.issid=iss.length]=this;this.imgs=imgs;if(imgs.random)
this.imgs.sort(function(){return 0.5-Math.random();})
this.imgborder=imgs.border?parseInt(imgs.border):0;if(!this.dom){this.postimgs=new Array()
for(p=0;p<imgs.length;p++){this.postimgs[p]=new Image()
this.postimgs[p].src=this.imgs[p][0]}}
if(this.dom){this.faded=0;this.loadimgidx=[];this.fade=!imgs.nofade;if(this.fade)
this.degree=10
this.pausecheck=imgs.pause;this.mouseovercheck=0
this.canvasbase="canvas"+this.issid
this.curcanvas=this.canvasbase+"_0"
this.descriptions=!imgs.no_descriptions;this.man_start=imgs.manual_start;this.addbr=!imgs.no_added_linebreaks;this.no_auto=imgs.no_auto;this.onclick=imgs.onclick;this.specs=imgs.specs;this.counter=imgs.counter;this.ics=imgs.image_controls;this.jumpto=imgs.jumpto;this.no_c=imgs.no_controls;this.target=imgs.target;this.ualt=imgs.use_alt;this.utit=imgs.use_title;this.fadecolor=imgs.fadecolor;this.ibut_hc=imgs.button_highlight;this.dp=imgs.desc_prefix?imgs.desc_prefix:' ';this.imbcolor=imgs.border_color;this.imbstyle=imgs.border_style;this.width=imgs.width?imgs.width:width?width:null
this.width=this.width?this.width+this.imgborder*2:null;this.height=imgs.height?imgs.height:height?height:null
this.height=this.height?this.height+this.imgborder*2:null;var ief='',dims='';if(this.width||this.height)
dims=this.width&&this.height?'width:'+this.width+'px;height:'+this.height+'px;':this.width?'width:'+this.width+'px;':'height:'+this.height+'px;';if(this.fade&&document.body&&document.body.style)
ief=document.body.filters?'filter:progid:DXImageTransform.Microsoft.alpha(opacity=0);':typeof document.body.style.opacity=='string'?'opacity:0;':'opacity:0.10;-moz-opacity:0.10;-khtml-opacity:0.10;';var brs=this.addbr?'<br>':'';if(imgs.controls_top){this.controls();document.write(brs)}
document.write('<div align="center"><div id="master'+this.issid+'" style="position:relative;'+dims+'overflow:hidden;margin:0 auto;"><div id="'+this.canvasbase+'_0" style="position:absolute;'+dims+'top:0;left:0;'+ief+'background-color:'+(imgs.fadecolor?imgs.fadecolor:'white')+'"><\/div><div id="'+this.canvasbase+'_1" style="position:absolute;'+dims+'top:0;left:0;'+ief+'background-color:'+(imgs.fadecolor?imgs.fadecolor:'white')+'"><\/div><\/div><\/div>')
if(this.descriptions)
document.write(brs+'<div align="center">'+this.dp+'<span id="imgdsc'+this.issid+'">&nbsp;<\/span></div>\n');if(this.counter&&!this.descriptions)
document.write(brs);if(this.counter)
this.cntrl()
if(!imgs.controls_top){document.write(this.ics?'':brs);this.controls();}}
else
document.write('<div align="center"><img name="defaultslide'+this.issid+'" src="'+this.postimgs[0].src+'"><\/div>')
if(this.dom)
this.startit()
else{this.nextimgidx++
setInterval("iss["+this.issid+"].rotateimg()",this.delay)}}
inter_slide.prototype.cntrl=function(){this.cpad=this.imgs.length.toString().length;document.write('<div align="center">Viewing Image: <b><span id="thecnt'+this.issid+'"><\/span><\/b> of<span style="font-size:1ex;">&nbsp;</span>&nbsp;<b>'+this.imgs.length+'<\/b><\/div>');}
inter_slide.prototype.controls=function(){var brs=this.addbr?'<br>':' &nbsp;';if(!this.ics&&!this.no_c)
document.write('<div align="center"><input id="prev'+this.issid+'" disabled type="button" value=" << " onclick="iss['+this.issid+'].changeimg(false, \'nav\');">\n'+
(this.no_auto?'&nbsp;&nbsp;&nbsp;':' <input id="gostp'+this.issid+'" type="button" value=" Stop " onclick="iss['+this.issid+'].gostop(this);">\n')+' <input id="next'+this.issid+'" disabled type="button" value=" >> " onclick="iss['+this.issid+'].changeimg(true, \'nav\');">'+(this.jumpto?brs+'Jump to: <input disabled type="text" size="'+this.imgs.length.toString().length+'" id="goto'+this.issid+'" onkeydown="iss['+this.issid+'].jumper(event);"><input id="go'+this.issid+'" disabled type="button" onclick="iss['+this.issid+'].jumper();" value="GO">':'')+'<\/div>')
else if(this.ics&&!this.no_c){var op=document.body.filters?' style="filter:alpha(opacity=100);"':' style="opacity:'+(this.man_start?0.99:0.45)+';"';document.write('<table align="center" style="width:571px;background-color:#EEF4F2;" cellpadding="0" cellspacing="2"><tr><td valign="middle" style="padding:2px 2px 1px 2px;width:278px;text-align:right"><input'+op+' onmouseover="iss['+this.issid+'].ibute(this,1);" onmouseout="iss['+this.issid+'].ibute(this,2);" onmousedown="iss['+this.issid+'].ibute(this,3);" onmouseup="iss['+this.issid+'].ibute(this,4);" type="image" title="Previous" id="prev'+this.issid+'" src="'+previmg+'" onclick="iss['+this.issid+'].changeimg(false, \'nav\');"><\/td>'+(this.no_auto?'<td>&nbsp;<\/td>':'<td valign="middle" align="center" style="text-align:center;padding:2px 2px 1px 2px;width:15px"><input onmouseover="iss['+this.issid+'].ibute(this,1);" onmouseout="iss['+this.issid+'].ibute(this,2);" onmousedown="iss['+this.issid+'].ibute(this,3);" onmouseup="iss['+this.issid+'].ibute(this,4);" title="Stop" type="image" id="gostp'+this.issid+'" src="'+(this.g_fPlayMode?playimg:stopimg)+'" onclick="iss['+this.issid+'].gostop(this);"><\/td>')+'<td valign="middle" style="padding:2px 2px 1px 2px;width:278px;text-align:left"><input'+op+' onmouseover="iss['+this.issid+'].ibute(this,1);" onmouseout="iss['+this.issid+'].ibute(this,2);" onmousedown="iss['+this.issid+'].ibute(this,3);" onmouseup="iss['+this.issid+'].ibute(this,4);" type="image" title="Next" id="next'+this.issid+'" src="'+nextimg+'" onclick="iss['+this.issid+'].changeimg(true, \'nav\');"><\/td><\/tr><\/table>\n');}
else
this.no_c=1;}
inter_slide.prototype.jumper=function(e){var key;if(typeof e=='object')
key=e.keyCode?e.keyCode:e.which?e.which:1;if(key&&key!==13)
return;var num=typeof e=='number'?e:parseInt(this.go('goto'+this.issid).value);if(num<=this.imgs.length&&num>0){this.nextimgidx=num-2;this.changeimg(true,'jump');}}
inter_slide.prototype.ibute=function(obj,i){if(!obj.parentNode)
return;if(i==1)
obj.parentNode.style.backgroundColor=this.ibut_hc?this.ibut_hc:'yellow';else if(i==2)
obj.parentNode.style.backgroundColor='transparent';else if(i==3){obj.parentNode.style.borderTop=obj.parentNode.style.borderLeft='1px solid gray';obj.parentNode.style.paddingRight='1px';obj.parentNode.style.paddingBottom=0;}
if(i==2||i==4){obj.parentNode.style.borderTop=obj.parentNode.style.borderLeft='none';obj.parentNode.style.paddingRight='2px';obj.parentNode.style.paddingBottom='1px';}}
inter_slide.prototype.fadepic=function(){if(this.fade&&this.degree<100){this.faded=0
this.degree+=10
if(this.tempobj.filters&&this.tempobj.filters[0]){if(typeof this.tempobj.filters[0].opacity=="number")
this.tempobj.filters[0].opacity=this.degree
else
this.tempobj.style.filter="alpha(opacity="+this.degree+")"}
else if(this.tempobj.style.MozOpacity)
this.tempobj.style.MozOpacity=this.degree/101
else if(this.tempobj.style.KhtmlOpacity)
this.tempobj.style.KhtmlOpacity=this.degree/100
else if(this.tempobj.style.opacity&&!this.tempobj.filters)
this.tempobj.style.opacity=this.degree/101}
else{this.faded=1
clearInterval(this.fadeclear)
this.nextcanvas=(this.curcanvas==this.canvasbase+"_0")?this.canvasbase+"_0":this.canvasbase+"_1"
this.tempobj=this.go(this.nextcanvas)
if(this.playing)
this.changeimg()}}
inter_slide.prototype.populateslide=function(picobj,picidx){if(document.getElementsByTagName){if(picobj.getElementsByTagName('a')[0]&&picobj.getElementsByTagName('a')[0].onclick)
picobj.getElementsByTagName('a')[0].onclick=null;if(picobj.getElementsByTagName('img')[0]&&picobj.getElementsByTagName('img')[0].onload)
picobj.getElementsByTagName('img')[0].onload=null;}
picobj.style.backgroundColor=this.imgs[picidx].fadecolor?this.imgs[picidx].fadecolor:this.fadecolor?this.fadecolor:'white';var slideHTML='<table border="0" cellpadding="0" cellspacing="0" width="100%" height="100%"><tr><td width="100%" height="100%" align="center" valign="middle" style="background:transparent none;">'
if(this.imgs[picidx][2]){var specs=this.imgs[picidx][4]?", '"+this.imgs[picidx][4]+"'":this.specs?", '"+this.specs+"'":'';slideHTML+='<a href="'+this.imgs[picidx][2]+'"'+(this.imgs[picidx][3]?' target="'+this.imgs[picidx][3]+'"':this.target?' target="'+this.target+'"':'')+' onclick="'+(this.onclick?this.onclick:'window.open(this.href, (this.target? this.target : \'_self\')'+specs+');return false;')+'">'}
slideHTML+='<img id="theimg'+picidx+'_'+this.issid+'" src="'+(this.loadimgidx[picidx]&&typeof this.loadimgidx[picidx].complete=='boolean'&&this.loadimgidx[picidx].complete?this.loadimgidx[picidx].src:this.imgs[picidx][0])+'" alt="'+(this.ualt?this.imgs[picidx][1]:'Slide Show Image')+'" title="'+(this.utit?this.imgs[picidx][1]:'')+'" '+(this.imbcolor&&!this.imgs[picidx].noborder?'style="border:'+this.imgborder+'px '+(this.imbstyle?this.imbstyle:'solid')+' '+this.imbcolor+';"':'border="'+(this.imgs[picidx].noborder?'0':this.imgborder)+'"')+(!this.width||!this.height?' onload="iss['+this.issid+'].imgload(this);"':'')+'>'
if(this.imgs[picidx][2])
slideHTML+='<\/a>'
slideHTML+='<\/td><\/tr><\/table>'
picobj.innerHTML=slideHTML}
inter_slide.prototype.buttons=function(bool){if(this.no_c)
return;var next=this.go('next'+this.issid),prev=this.go('prev'+this.issid);next.disabled=prev.disabled=!bool;next.title=bool?'next':'';prev.title=bool?'previous':'';if(this.jumpto&&!this.ics)
this.go('go'+this.issid).disabled=this.go('goto'+this.issid).disabled=!bool;if(this.ics){if(!this.no_auto){var go=this.go('gostp'+this.issid)
go.title=bool?'Play':'Stop';go.src=bool?playimg:stopimg;}
if(prev.filters&&prev.parentNode)
prev.parentNode.style.filter=next.parentNode.style.filter='alpha(opacity='+(bool?100:45)+')';else if(prev.style.opacity&&!prev.filters)
prev.style.opacity=next.style.opacity=bool?0.99:0.45;}}
inter_slide.prototype.imgload=function(el){if(!el&&!this.imgel)
return;var el=el?el:this.imgel;if(el.width==0||el.height==0){this.imgel=el;var cacheobj=this;clearTimeout(this.getdim)
this.getdim=setTimeout(function(){cacheobj.imgload()},300)
return;}
var m=this.go('master'+this.issid).style,c0=this.go(this.canvasbase+'_0').style,c1=this.go(this.canvasbase+'_1').style;if(!this.width){this.width=el.width+this.imgborder*2;m.width=c0.width=c1.width=this.width+'px';}
if(!this.height){this.height=el.height+this.imgborder*2;m.height=c0.height=c1.height=this.height+'px';}}
inter_slide.prototype.changeimg=function(bool,nav){if(this.playing){this.buttons(false)
this.nextimgidx=(this.keeptrack()<this.imgs.length-1)?this.keeptrack()+1:0
this.populateslide(this.tempobj,this.nextimgidx)
if(bool)
this.rotateimg()
else{clearTimeout(this.inprocess)
this.inprocess=setTimeout("iss["+this.issid+"].rotateimg()",this.delay)}}
else{if(!this.faded){if(nav&&nav=='nav')
return;this.nextimgidx=this.keeptrack()+(bool?1:-1)
this.nextimgidx=(this.nextimgidx<this.imgs.length)?this.nextimgidx:this.nextimgidx-this.imgs.length
this.nextimgidx=(this.nextimgidx>-1)?this.nextimgidx:this.imgs.length+this.nextimgidx
return;}
if(this.fadeclear)
clearInterval(this.fadeclear);if(bool){var loadidx=this.nextimgidx+2
loadidx=(loadidx<this.imgs.length)?loadidx:loadidx-this.imgs.length;loadidx=(loadidx>-1)?loadidx:this.imgs.length+loadidx;this.loadimgidx[loadidx]=new Image();this.loadimgidx[loadidx].src=this.imgs[loadidx][0];}
else{var loadidx=this.nextimgidx-2
loadidx=(loadidx<this.imgs.length)?loadidx:loadidx-this.imgs.length
loadidx=(loadidx>-1)?loadidx:this.imgs.length+loadidx
this.loadimgidx[loadidx]=new Image();this.loadimgidx[loadidx].src=this.imgs[loadidx][0];}
if(nav&&nav=='jump')
this.nextimgidx++;else
this.nextimgidx=this.keeptrack()+(bool?1:-1)
this.nextimgidx=(this.nextimgidx<this.imgs.length)?this.nextimgidx:this.nextimgidx-this.imgs.length
this.nextimgidx=(this.nextimgidx>-1)?this.nextimgidx:this.imgs.length+this.nextimgidx
this.populateslide(this.tempobj,this.nextimgidx)
this.rotateimg()}}
inter_slide.prototype.go=function(id){return this.da?this.da[id]:document.getElementById(id);}
inter_slide.prototype.rotateimg=function(){if(this.dom){var cimg=this.go('theimg'+this.nextimgidx+'_'+this.issid)?this.go('theimg'+this.nextimgidx+'_'+this.issid):null;if(cimg&&typeof cimg.complete=='boolean'&&!cimg.complete){var cacheobj=this
clearTimeout(this.loading)
this.loading=setTimeout(function(){cacheobj.rotateimg()},300)
return;}
if(this.mouseovercheck==1){var cacheobj=this
clearTimeout(this.mousep)
this.mousep=setTimeout(function(){cacheobj.rotateimg()},100)
return;}
if(this.fade)
this.resetit()
var crossobj=this.tempobj=this.go(this.curcanvas)
crossobj.style.zIndex++
var othercanvas=this.curcanvas==this.canvasbase+"_0"?this.go(this.canvasbase+"_1"):this.go(this.canvasbase+"_0");othercanvas.style.zIndex=0;if(this.descriptions)
this.go('imgdsc'+this.issid).innerHTML=this.imgs[this.keeptrack()][1];if(this.counter){var padit='';for(var p=0;p<this.cpad-(this.nextimgidx+1).toString().length;p++)
padit+='<span style="visibility:hidden;">0</span>';this.go('thecnt'+this.issid).innerHTML=padit+(this.keeptrack()<this.imgs.length?this.keeptrack()+1:1);}
if(this.jumpto)
this.go('goto'+this.issid).value=this.keeptrack()<this.imgs.length?this.keeptrack()+1:1;this.jumperidx=this.keeptrack()<this.imgs.length?this.keeptrack()+1:1;var fadeobj=this
clearInterval(this.fadeclear)
this.fadeclear=setInterval(function(){fadeobj.fadepic()},50)
this.curcanvas=(this.curcanvas==this.canvasbase+"_0")?this.canvasbase+"_1":this.canvasbase+"_0"}
else{var v4imgobj=document.images['defaultslide'+this.issid]
v4imgobj.src=this.postimgs[this.nextimgidx].src
this.nextimgidx=(this.nextimgidx<this.imgs.length-1)?this.nextimgidx+1:0}}
inter_slide.prototype.resetit=function(){this.degree=10
var crossobj=this.go(this.curcanvas)
if(crossobj.filters&&crossobj.filters[0]){if(typeof crossobj.filters[0].opacity=="number")
crossobj.filters(0).opacity=this.degree
else
crossobj.style.filter="alpha(opacity="+this.degree+")"}
else if(crossobj.style.MozOpacity)
crossobj.style.MozOpacity=this.degree/101
else if(crossobj.style.KhtmlOpacity)
crossobj.style.KhtmlOpacity=this.degree/100
else if(crossobj.style.opacity&&!crossobj.filters)
crossobj.style.opacity=this.degree/101}
inter_slide.prototype.startit=function(){this.playing=1
var crossobj=this.go(this.curcanvas)
this.populateslide(crossobj,this.nextimgidx)
if(this.pausecheck==1){var cacheobj=this
var crossobjcontainer=this.go("master"+this.issid)
crossobjcontainer.onmouseover=function(){cacheobj.mouseovercheck=1}
crossobjcontainer.onmouseout=function(){cacheobj.mouseovercheck=0}}
this.rotateimg()
if(this.no_auto)
this.gostop();else if(this.man_start)
this.gostop(this.go('gostp'+this.issid));else if(this.ics&&document.body.filters){this.buttons(false);}}
inter_slide.prototype.gostop=function(el){if(el)
el.value=el.value==' Stop '?' Play ':' Stop ';if(this.inprocess&&this.playing){clearTimeout(this.inprocess);this.nextimgidx-=this.faded;}
this.playing=!this.playing;if(this.playing){clearInterval(this.fadeclear)
this.faded=1
this.changeimg(true);}
else{var loadidx=(this.keeptrack()<this.imgs.length-1)?this.keeptrack()+1:0
this.loadimgidx[loadidx]=new Image();this.loadimgidx[loadidx].src=this.imgs[loadidx][0];this.jumper(this.jumperidx?this.jumperidx:0)
this.buttons(true);}}
inter_slide.prototype.keeptrack=function(){if(!document.getElementsByTagName)
return this.nextimgidx;var canvases=[this.go('canvas'+this.issid+'_0'),this.go('canvas'+this.issid+'_1')]
if(canvases[0].style.zIndex>canvases[1].style.zIndex&&canvases[0].getElementsByTagName("img")[0])
return parseInt(canvases[0].getElementsByTagName('img')[0].id.replace(/theimg/,''))
else if(canvases[1].getElementsByTagName("img")[0])
return parseInt(canvases[1].getElementsByTagName('img')[0].id.replace(/theimg/,''))
else
return this.nextimgidx;};var month='*';var day='15';var dow=0;var hour=0;var tz=0;var lab='cd';function start(){displayCountdown(setCountdown(month,day,hour,tz),lab);}
loaded(lab,start);var pageLoaded=0;window.onload=function(){pageLoaded=1;}
function loaded(i,f){if(document.getElementById&&document.getElementById(i)!=null)f();else if(!pageLoaded)setTimeout('loaded(\''+i+'\','+f+')',100);}
function setCountdown(month,day,hour,tz){var m=month;if(month=='*')m=0;var c=setC(m,day,hour,tz);if(month=='*'&&c<0)c=setC('*',day,hour,tz);return c;}function setC(month,day,hour,tz){var toDate=new Date();if(day.substr(0,1)=='+'){var day1=parseInt(day.substr(1));toDate.setDate(toDate.getDate()+day1);}else{toDate.setDate(day);}if(month=='*')toDate.setMonth(toDate.getMonth()+1);else if(month>0){if(month<=toDate.getMonth())toDate.setYear(toDate.getYear()+1);toDate.setMonth(month-1);}
if(dow>0)toDate.setDate(toDate.getDate()+(dow-1-toDate.getDay())%7);toDate.setHours(hour);toDate.setMinutes(0-(tz*60));toDate.setSeconds(0);var fromDate=new Date();fromDate.setMinutes(fromDate.getMinutes()+fromDate.getTimezoneOffset());var diffDate=new Date(0);diffDate.setMilliseconds(toDate-fromDate);return Math.floor(diffDate.valueOf()/1000);}
function displayCountdown(countdn,cd){if(countdn<0)document.getElementById(cd).innerHTML="CALL NOW";else{var secs=countdn%60;if(secs<10)secs='0'+secs;var countdn1=(countdn-secs)/60;var mins=countdn1%60;if(mins<10)mins='0'+mins;countdn1=(countdn1-mins)/60;var hours=countdn1%24;var days=(countdn1-hours)/24;document.getElementById(cd).innerHTML=days+' DAYS, '+hours+' HOURS, '+mins+' MINUTES '+secs;setTimeout('displayCountdown('+(countdn-1)+',\''+cd+'\');',999);}}
