var Callouts_CurrentTab = 1;
var CurrentTime = new Date();
var Callouts_DeadTime = CurrentTime.getTime();
var Callouts_WaitTime = 10000;

var NOFLASH_URL = "noflash.html";
var FLASH_VERSION = 8;
var FLASH_BUILD = 0;
var FLASH_MENU = true;

function genericFlashObject(url, x, y, flashVars, winMode)
{
	if (!winMode) winMode = "windowed";
	
	if (flashVars)
	{
		return({ 
			movie:url, 
			width:String(x), height:String(y), 
			majorversion:String(FLASH_VERSION), 
			build:String(FLASH_BUILD),
			menu:String(FLASH_MENU),
			flashvars:flashVars,
			wmode:winMode
		});
		
	}
	else
	{
		return({ 
			movie:url, 
			width:String(x), height:String(y), 
			majorversion:String(FLASH_VERSION), 
			build:String(FLASH_BUILD),
			menu:String(FLASH_MENU),
			wmode:winMode
		});
	}
}

function launchBooking()
{
	window.open('/BookYourETrip.aspx','booking','height=510,width=462,scrollbars');
}

function openMap()
{
	window.open('/map/map.htm','map','height=600,width=800');
}

function subRollOver(num)
{
	var image = document.getElementById("sub-nav").firstChild;
	image.src="/images/8D708735-CA80-0A13-F251-4D65181BE1E6/subnav_rollover/"+num+".gif";
	image.border = 0;
	image.hspace = 0;
}

function subRollOut()
{
	var image = document.getElementById("sub-nav").firstChild;
	image.src="/images/8D708735-CA80-0A13-F251-4D65181BE1E6/subnav_off.gif";	
}

function DatePicker(oDoc,cDate)
{ 
	window.open("/datepicker.asp?backf="+oDoc+"&cDate="+cDate, "DateWindow", "resizable=no,width=300,height=210,status=no,menubar=no,toolbar=no,scrollbars=no");
}

/*	SWFObject v2.0 <http://code.google.com/p/swfobject/>
	Copyright (c) 2007 Geoff Stearns, Michael Williams, and Bobby van der Sluis
	This software is released under the MIT License <http://www.opensource.org/licenses/mit-license.php>
*/
var swfobject=function(){var Z="undefined",P="object",B="Shockwave Flash",h="ShockwaveFlash.ShockwaveFlash",W="application/x-shockwave-flash",K="SWFObjectExprInst",G=window,g=document,N=navigator,f=[],H=[],Q=null,L=null,T=null,S=false,C=false;var a=function(){var l=typeof g.getElementById!=Z&&typeof g.getElementsByTagName!=Z&&typeof g.createElement!=Z&&typeof g.appendChild!=Z&&typeof g.replaceChild!=Z&&typeof g.removeChild!=Z&&typeof g.cloneNode!=Z,t=[0,0,0],n=null;if(typeof N.plugins!=Z&&typeof N.plugins[B]==P){n=N.plugins[B].description;if(n){n=n.replace(/^.*\s+(\S+\s+\S+$)/,"$1");t[0]=parseInt(n.replace(/^(.*)\..*$/,"$1"),10);t[1]=parseInt(n.replace(/^.*\.(.*)\s.*$/,"$1"),10);t[2]=/r/.test(n)?parseInt(n.replace(/^.*r(.*)$/,"$1"),10):0}}else{if(typeof G.ActiveXObject!=Z){var o=null,s=false;try{o=new ActiveXObject(h+".7")}catch(k){try{o=new ActiveXObject(h+".6");t=[6,0,21];o.AllowScriptAccess="always"}catch(k){if(t[0]==6){s=true}}if(!s){try{o=new ActiveXObject(h)}catch(k){}}}if(!s&&o){try{n=o.GetVariable("$version");if(n){n=n.split(" ")[1].split(",");t=[parseInt(n[0],10),parseInt(n[1],10),parseInt(n[2],10)]}}catch(k){}}}}var v=N.userAgent.toLowerCase(),j=N.platform.toLowerCase(),r=/webkit/.test(v)?parseFloat(v.replace(/^.*webkit\/(\d+(\.\d+)?).*$/,"$1")):false,i=false,q=j?/win/.test(j):/win/.test(v),m=j?/mac/.test(j):/mac/.test(v);/*@cc_on i=true;@if(@_win32)q=true;@elif(@_mac)m=true;@end@*/return{w3cdom:l,pv:t,webkit:r,ie:i,win:q,mac:m}}();var e=function(){if(!a.w3cdom){return }J(I);if(a.ie&&a.win){try{g.write("<script id=__ie_ondomload defer=true src=//:><\/script>");var i=c("__ie_ondomload");if(i){i.onreadystatechange=function(){if(this.readyState=="complete"){this.parentNode.removeChild(this);V()}}}}catch(j){}}if(a.webkit&&typeof g.readyState!=Z){Q=setInterval(function(){if(/loaded|complete/.test(g.readyState)){V()}},10)}if(typeof g.addEventListener!=Z){g.addEventListener("DOMContentLoaded",V,null)}M(V)}();function V(){if(S){return }if(a.ie&&a.win){var m=Y("span");try{var l=g.getElementsByTagName("body")[0].appendChild(m);l.parentNode.removeChild(l)}catch(n){return }}S=true;if(Q){clearInterval(Q);Q=null}var j=f.length;for(var k=0;k<j;k++){f[k]()}}function J(i){if(S){i()}else{f[f.length]=i}}function M(j){if(typeof G.addEventListener!=Z){G.addEventListener("load",j,false)}else{if(typeof g.addEventListener!=Z){g.addEventListener("load",j,false)}else{if(typeof G.attachEvent!=Z){G.attachEvent("onload",j)}else{if(typeof G.onload=="function"){var i=G.onload;G.onload=function(){i();j()}}else{G.onload=j}}}}}function I(){var l=H.length;for(var j=0;j<l;j++){var m=H[j].id;if(a.pv[0]>0){var k=c(m);if(k){H[j].width=k.getAttribute("width")?k.getAttribute("width"):"0";H[j].height=k.getAttribute("height")?k.getAttribute("height"):"0";if(O(H[j].swfVersion)){if(a.webkit&&a.webkit<312){U(k)}X(m,true)}else{if(H[j].expressInstall&&!C&&O("6.0.65")&&(a.win||a.mac)){D(H[j])}else{d(k)}}}}else{X(m,true)}}}function U(m){var k=m.getElementsByTagName(P)[0];if(k){var p=Y("embed"),r=k.attributes;if(r){var o=r.length;for(var n=0;n<o;n++){if(r[n].nodeName.toLowerCase()=="data"){p.setAttribute("src",r[n].nodeValue)}else{p.setAttribute(r[n].nodeName,r[n].nodeValue)}}}var q=k.childNodes;if(q){var s=q.length;for(var l=0;l<s;l++){if(q[l].nodeType==1&&q[l].nodeName.toLowerCase()=="param"){p.setAttribute(q[l].getAttribute("name"),q[l].getAttribute("value"))}}}m.parentNode.replaceChild(p,m)}}function F(i){if(a.ie&&a.win&&O("8.0.0")){G.attachEvent("onunload",function(){var k=c(i);if(k){for(var j in k){if(typeof k[j]=="function"){k[j]=function(){}}}k.parentNode.removeChild(k)}})}}function D(j){C=true;var o=c(j.id);if(o){if(j.altContentId){var l=c(j.altContentId);if(l){L=l;T=j.altContentId}}else{L=b(o)}if(!(/%$/.test(j.width))&&parseInt(j.width,10)<310){j.width="310"}if(!(/%$/.test(j.height))&&parseInt(j.height,10)<137){j.height="137"}g.title=g.title.slice(0,47)+" - Flash Player Installation";var n=a.ie&&a.win?"ActiveX":"PlugIn",k=g.title,m="MMredirectURL="+G.location+"&MMplayerType="+n+"&MMdoctitle="+k,p=j.id;if(a.ie&&a.win&&o.readyState!=4){var i=Y("div");p+="SWFObjectNew";i.setAttribute("id",p);o.parentNode.insertBefore(i,o);o.style.display="none";G.attachEvent("onload",function(){o.parentNode.removeChild(o)})}R({data:j.expressInstall,id:K,width:j.width,height:j.height},{flashvars:m},p)}}function d(j){if(a.ie&&a.win&&j.readyState!=4){var i=Y("div");j.parentNode.insertBefore(i,j);i.parentNode.replaceChild(b(j),i);j.style.display="none";G.attachEvent("onload",function(){j.parentNode.removeChild(j)})}else{j.parentNode.replaceChild(b(j),j)}}function b(n){var m=Y("div");if(a.win&&a.ie){m.innerHTML=n.innerHTML}else{var k=n.getElementsByTagName(P)[0];if(k){var o=k.childNodes;if(o){var j=o.length;for(var l=0;l<j;l++){if(!(o[l].nodeType==1&&o[l].nodeName.toLowerCase()=="param")&&!(o[l].nodeType==8)){m.appendChild(o[l].cloneNode(true))}}}}}return m}function R(AE,AC,q){var p,t=c(q);if(typeof AE.id==Z){AE.id=q}if(a.ie&&a.win){var AD="";for(var z in AE){if(AE[z]!=Object.prototype[z]){if(z=="data"){AC.movie=AE[z]}else{if(z.toLowerCase()=="styleclass"){AD+=' class="'+AE[z]+'"'}else{if(z!="classid"){AD+=" "+z+'="'+AE[z]+'"'}}}}}var AB="";for(var y in AC){if(AC[y]!=Object.prototype[y]){AB+='<param name="'+y+'" value="'+AC[y]+'" />'}}t.outerHTML='<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"'+AD+">"+AB+"</object>";F(AE.id);p=c(AE.id)}else{if(a.webkit&&a.webkit<312){var AA=Y("embed");AA.setAttribute("type",W);for(var x in AE){if(AE[x]!=Object.prototype[x]){if(x=="data"){AA.setAttribute("src",AE[x])}else{if(x.toLowerCase()=="styleclass"){AA.setAttribute("class",AE[x])}else{if(x!="classid"){AA.setAttribute(x,AE[x])}}}}}for(var w in AC){if(AC[w]!=Object.prototype[w]){if(w!="movie"){AA.setAttribute(w,AC[w])}}}t.parentNode.replaceChild(AA,t);p=AA}else{var s=Y(P);s.setAttribute("type",W);for(var v in AE){if(AE[v]!=Object.prototype[v]){if(v.toLowerCase()=="styleclass"){s.setAttribute("class",AE[v])}else{if(v!="classid"){s.setAttribute(v,AE[v])}}}}for(var u in AC){if(AC[u]!=Object.prototype[u]&&u!="movie"){E(s,u,AC[u])}}t.parentNode.replaceChild(s,t);p=s}}return p}function E(k,i,j){var l=Y("param");l.setAttribute("name",i);l.setAttribute("value",j);k.appendChild(l)}function c(i){return g.getElementById(i)}function Y(i){return g.createElement(i)}function O(k){var j=a.pv,i=k.split(".");i[0]=parseInt(i[0],10);i[1]=parseInt(i[1],10);i[2]=parseInt(i[2],10);return(j[0]>i[0]||(j[0]==i[0]&&j[1]>i[1])||(j[0]==i[0]&&j[1]==i[1]&&j[2]>=i[2]))?true:false}function A(m,j){if(a.ie&&a.mac){return }var l=g.getElementsByTagName("head")[0],k=Y("style");k.setAttribute("type","text/css");k.setAttribute("media","screen");if(!(a.ie&&a.win)&&typeof g.createTextNode!=Z){k.appendChild(g.createTextNode(m+" {"+j+"}"))}l.appendChild(k);if(a.ie&&a.win&&typeof g.styleSheets!=Z&&g.styleSheets.length>0){var i=g.styleSheets[g.styleSheets.length-1];if(typeof i.addRule==P){i.addRule(m,j)}}}function X(k,i){var j=i?"visible":"hidden";if(S){c(k).style.visibility=j}else{A("#"+k,"visibility:"+j)}}return{registerObject:function(l,i,k){if(!a.w3cdom||!l||!i){return }var j={};j.id=l;j.swfVersion=i;j.expressInstall=k?k:false;H[H.length]=j;X(l,false)},getObjectById:function(l){var i=null;if(a.w3cdom&&S){var j=c(l);if(j){var k=j.getElementsByTagName(P)[0];if(!k||(k&&typeof j.SetVariable!=Z)){i=j}else{if(typeof k.SetVariable!=Z){i=k}}}}return i},embedSWF:function(n,u,r,t,j,m,k,p,s){if(!a.w3cdom||!n||!u||!r||!t||!j){return }r+="";t+="";if(O(j)){X(u,false);var q=(typeof s==P)?s:{};q.data=n;q.width=r;q.height=t;var o=(typeof p==P)?p:{};if(typeof k==P){for(var l in k){if(k[l]!=Object.prototype[l]){if(typeof o.flashvars!=Z){o.flashvars+="&"+l+"="+k[l]}else{o.flashvars=l+"="+k[l]}}}}J(function(){R(q,o,u);if(q.id==u){X(u,true)}})}else{if(m&&!C&&O("6.0.65")&&(a.win||a.mac)){X(u,false);J(function(){var i={};i.id=i.altContentId=u;i.width=r;i.height=t;i.expressInstall=m;D(i)})}}},getFlashPlayerVersion:function(){return{major:a.pv[0],minor:a.pv[1],release:a.pv[2]}},hasFlashPlayerVersion:O,createSWF:function(k,j,i){if(a.w3cdom&&S){return R(k,j,i)}else{return undefined}},createCSS:function(j,i){if(a.w3cdom){A(j,i)}},addDomLoadEvent:J,addLoadEvent:M,getQueryParamValue:function(m){var l=g.location.search||g.location.hash;if(m==null){return l}if(l){var k=l.substring(1).split("&");for(var j=0;j<k.length;j++){if(k[j].substring(0,k[j].indexOf("="))==m){return k[j].substring((k[j].indexOf("=")+1))}}}return""},expressInstallCallback:function(){if(C&&L){var i=c(K);if(i){i.parentNode.replaceChild(L,i);if(T){X(T,true);if(a.ie&&a.win){L.style.display="block"}}L=null;T=null;C=false}}}}}();

/**
 * SWFAddress 2.1: Deep linking for Flash and Ajax - http://www.asual.com/swfaddress/
 *
 * SWFAddress is (c) 2006-2007 Rostislav Hristov and is released under the MIT License:
 * http://www.opensource.org/licenses/mit-license.php
 *
 */
if(typeof com=="undefined"){var com={}}if(typeof com.asual=="undefined"){com.asual={}}if(typeof com.asual.util=="undefined"){com.asual.util={}}com.asual.util.Browser=new function(){var J=-1;var I=navigator.userAgent;var H=false,F=false,E=false,D=false,C=false,B=false,A=false;var G=function(L,K){return parseFloat(I.substr(I.indexOf(L)+K))};if(H=/MSIE/.test(I)){J=G("MSIE",4)}if(E=/AppleWebKit/.test(I)){J=G("Safari",7)}if(D=/Opera/.test(I)){J=parseFloat(navigator.appVersion)}if(F=/Camino/.test(I)){J=G("Camino",7)}if(C=/Firefox/.test(I)){J=G("Firefox",8)}if(B=/Netscape/.test(I)){J=G("Netscape",9)}if(A=/Mozilla/.test(I)&&/rv:/.test(I)){J=G("rv:",3)}this.getVersion=function(){return J};this.isIE=function(){return H};this.isSafari=function(){return E};this.isOpera=function(){return D};this.isCamino=function(){return F};this.isFirefox=function(){return C};this.isNetscape=function(){return B};this.isMozilla=function(){return A}};com.asual.util.Events=new function(){var B=[];var A=com.asual.util.Browser;var D="DOMContentLoaded";if(A.isIE()||A.isSafari()){(function(){try{if(A.isIE()||!/loaded|complete/.test(document.readyState)){document.documentElement.doScroll("left")}}catch(F){return setTimeout(arguments.callee,0)}for(var E=0,F;F=B[E];E++){if(F.t==D){F.l.call(null)}}})()}this.addListener=function(G,F,E){B.push({o:G,t:F,l:E});if(!(F==D&&(A.isIE()||A.isSafari()))){if(G.addEventListener){G.addEventListener(F,E,false)}else{if(G.attachEvent){G.attachEvent("on"+F,E)}}}};this.removeListener=function(I,G,E){for(var F=0,H;H=B[F];F++){if(H.o==I&&H.t==G&&H.l==E){B.splice(F,1);break}}if(!(G==D&&(A.isIE()||A.isSafari()))){if(I.removeEventListener){I.removeEventListener(G,E,false)}else{if(I.detachEvent){I.detachEvent("on"+G,E)}}}};var C=function(){for(var F=0,E;E=B[F];F++){if(E.t!=D){com.asual.util.Events.removeListener(E.o,E.t,E.l)}}};this.addListener(window,"unload",C)};SWFAddressEvent=function(C){this.toString=function(){return"[object SWFAddressEvent]"};this.type=C;this.target=[SWFAddress][0];this.value=SWFAddress.getValue();this.path=SWFAddress.getPath();this.pathNames=SWFAddress.getPathNames();this.parameters={};var B=SWFAddress.getParameterNames();for(var D=0,A=B.length;D<A;D++){this.parameters[B[D]]=SWFAddress.getParameter(B[D])}this.parametersNames=B};SWFAddressEvent.INIT="init";SWFAddressEvent.CHANGE="change";SWFAddress=new function(){var _21=com.asual.util.Browser;var _22=com.asual.util.Events;var _23=_21.getVersion();var _24=false;if(_21.isIE()){_24=_23>=6}if(_21.isSafari()){_24=_23>=312}if(_21.isOpera()){_24=_23>=9.02}if(_21.isCamino()){_24=_23>=1}if(_21.isFirefox()){_24=_23>=1}if(_21.isNetscape()){_24=_23>=8}if(_21.isMozilla()){_24=_23>=1.8}var _t=top;var _d=_t.document;var _h=_t.history;var _l=_t.location;var _st=setTimeout;var _2a="function";var _2b="undefined";var _2c="swfaddress";var _2d,_2e,_2f;var _30=_d.title;var _31=_h.length;var _32=false;var _33={};var _34=[];var _35=[];var _36={};_36.history=true;_36.html=false;_36.strict=true;_36.tracker="_trackDefault";if((!_24&&_l.href.indexOf("#")!=-1)||(_21.isSafari()&&_23<412&&_l.href.indexOf("#")!=-1&&_l.search!="")){_d.open();_d.write('<html><head><meta http-equiv="refresh" content="0;url='+_l.href.substr(0,_l.href.indexOf("#"))+'" /></head></html>');_d.close()}var _37=function(){var _38=_l.href.indexOf("#");if(_38!=-1){var _39=unescape(_l.href.substr(_38+1));if(/^[a-z0-9 ,=_&\-\.\?\+\/]*$/i.test(_39)){return _39}else{_l.replace(_l.href.substr(0,_38))}}return""};var _3a=_37();var _3b=function(_3c,_3d){if(_36.strict){_3c=_3d?(_3c.substr(0,1)!="/"?"/"+_3c:_3c):(_3c==""?"/":_3c)}return _3c};var _3e=function(_3f){return(_21.isIE()&&_l.protocol=="file:")?_3a.replace(/\?/,"%3F"):_3f};var _40=function(el){if(el.src&&/swfaddress\.js(\?.*)?$/.test(el.src)){return el}for(var i=0,l=el.childNodes.length,s;i<l;i++){if(s=_40(el.childNodes[i])){return s}}};var _45=function(){if(_21.isIE()&&_d.title!=_30){SWFAddress.setTitle(_30)}};var _46=function(){if(!_32){var _47=_37();if(_21.isIE()){if(_3a!=_47){if(_23<7){_l.reload()}else{SWFAddress.setValue(_47)}}}else{if(_21.isSafari()&&_23<523){if(_31!=_h.length){_31=_h.length;if(typeof _34[_31-1]!=_2b){_3a=_34[_31-1]}_48()}}else{if(_3a!=_47){_3a=_47;_48()}}}_45()}};var _49=function(_4a){if(SWFAddress.hasEventListener(_4a)){SWFAddress.dispatchEvent(new SWFAddressEvent(_4a))}_4a=_4a.substr(0,1).toUpperCase()+_4a.substr(1);if(typeof SWFAddress["on"+_4a]==_2a){SWFAddress["on"+_4a]()}};var _4b=function(){_49("init")};var _4c=function(){_49("change")};var _4d=function(){for(var i=0,id,_50=SWFAddress.getValue(),_51="setSWFAddressValue";id=_35[i];i++){var obj=document.getElementById(id);if(obj){if(obj.parentNode&&typeof obj.parentNode.so!=_2b){obj.parentNode.so.call(_51,_50)}else{if(!(obj&&typeof obj[_51]!=_2b)){var _53=obj.getElementsByTagName("object");var _54=obj.getElementsByTagName("embed");obj=((_53[0]&&typeof _53[0][_51]!=_2b)?_53:((_54[0]&&typeof _54[0][_51]!=_2b)?_54[0]:null))}if(obj){obj[_51](_50)}}}else{if(obj=document[id]){if(typeof obj[_51]!=_2b){obj[_51](_50)}}}}};var _48=function(){_4d();_4c();_st(_55,10)};var _56=function(_57){if(typeof urchinTracker==_2a){urchinTracker(_57)}if(typeof pageTracker!=_2b&&typeof pageTracker._trackPageview==_2a){pageTracker._trackPageview(_57)}};eval("var _trackDefault = "+_56+";");var _55=function(){if(typeof _36.tracker!=_2b&&eval("typeof "+_36.tracker+' != "'+_2b+'"')){var fn=eval(_36.tracker);if(typeof fn==_2a){fn((_l.pathname+(/\/$/.test(_l.pathname)?"":"/")+SWFAddress.getValue()).replace(/\/\//,"/").replace(/^\/$/,""))}}};var _59=function(){var doc=_2d.contentWindow.document;doc.open();doc.write("<script>var "+_2c+' = "'+_37()+'";<\/script>');doc.close()};var _5b=function(){var win=_2d.contentWindow;if(_36.html){var src=win.location.href;_3a=(src.indexOf("?")>-1)?src.substr(src.indexOf("?")+1):""}else{_3a=(typeof win[_2c]!=_2b)?win[_2c]:""}win.document.title=_d.title;if(_3a!=_37()){_48();_l.hash=_3e(_3a)}};var _5e=function(){var _5f='id="'+_2c+'" style="position:absolute;top:-9999px;"';if(_21.isIE()){document.body.appendChild(document.createElement("div")).innerHTML="<iframe "+_5f+' src="'+(_36.html?_2f.replace(/\.js(\?.*)?$/,".html")+"?"+_37():"javascript:false;")+'" width="0" height="0"></iframe>';_2d=document.getElementById(_2c);_st(function(){_22.addListener(_2d,"load",_5b);if(!_36.html&&typeof _2d.contentWindow[_2c]==_2b){_59()}},10)}else{if(_21.isSafari()){if(_23<412){document.body.innerHTML+="<form "+_5f+' method="get"></form>';_2e=document.getElementById(_2c)}if(typeof _l[_2c]==_2b){_l[_2c]={}}if(typeof _l[_2c][_l.pathname]!=_2b){_34=_l[_2c][_l.pathname].split(",")}}else{if(_21.isOpera()&&_35.length==0&&typeof navigator.plugins["Shockwave Flash"]=="object"){document.body.innerHTML+="<embed "+_5f+' src="'+_2f.replace(/\.js(\?.*)?$/,".swf")+'" type="application/x-shockwave-flash" />'}}}_st(_4b,1);_st(_4c,2);_st(_55,10);setInterval(_46,50)};this.onInit=null;this.onChange=null;this.toString=function(){return"[class SWFAddress]"};this.back=function(){_h.back()};this.forward=function(){_h.forward()};this.go=function(_60){_h.go(_60)};this.href=function(url,_62){_62=(typeof _62!=_2b)?_62:"_self";if(_62=="_self"){self.location.href=url}if(_62=="_top"){_l.href=url}if(_62=="_blank"){window.open(url)}else{_t.frames[_62].location.href=url}};this.popup=function(url,_64,_65,_66){var _67=window.open(url,_64,eval(_65));eval(_66)};this.addEventListener=function(_68,_69){if(typeof _33[_68]==_2b){_33[_68]=[]}_33[_68].push(_69)};this.removeEventListener=function(_6a,_6b){if(typeof _33[_6a]!=_2b){for(var i=0,l;l=_33[_6a][i];i++){if(l==_6b){break}}_33[_6a].splice(i,1)}};this.dispatchEvent=function(_6e){if(typeof _33[_6e.type]!=_2b&&_33[_6e.type].length){_6e.target=this;for(var i=0,l;l=_33[_6e.type][i];i++){l(_6e)}return true}return false};this.hasEventListener=function(_71){return(typeof _33[_71]!=_2b&&_33[_71].length>0)};this.getBaseURL=function(){var url=_l.href;if(url.indexOf("#")!=-1){url=url.substr(0,url.indexOf("#"))}if(url.substr(url.length-1)=="/"){url=url.substr(0,url.length-1)}return url};this.getStrict=function(){return _36.strict};this.setStrict=function(_73){_36.strict=_73};this.getHistory=function(){return _36.history};this.setHistory=function(_74){_36.history=_74};this.getTracker=function(){return _36.tracker};this.setTracker=function(_75){_36.tracker=_75};this.getIds=function(){return _35};this.getId=function(_76){return _35[0]};this.setId=function(id){_35[0]=id};this.addId=function(id){this.removeId(id);_35.push(id)};this.removeId=function(id){for(var i=0;i<_35.length;i++){if(id==_35[i]){_35.splice(i,1);break}}};this.getTitle=function(){return _d.title};this.setTitle=function(_7b){if(!_24){return null}if(typeof _7b==_2b){return }if(_7b=="null"){_7b=""}_30=_d.title=_7b;_st(function(){if(_2d&&_2d.contentWindow&&_2d.contentWindow.document&&_2d.contentWindow.title){_2d.contentWindow.document.title=_30}},1000)};this.getStatus=function(){return _t.status};this.setStatus=function(_7c){if(!_24){return null}if(typeof _7c==_2b){return }if(!_21.isSafari()){_7c=_3b((_7c!="null")?_7c:"",true);if(_7c=="/"){_7c=""}if(!(/http(s)?:\/\//.test(_7c))){var _7d=_l.href.indexOf("#");_7c=(_7d==-1?_l.href:_l.href.substr(0,_7d))+"#"+_7c}_t.status=_7c}};this.resetStatus=function(){_t.status=""};this.getValue=function(){if(!_24){return null}return _3b(_3a,false)};this.setValue=function(_7e){if(!_24){return null}if(typeof _7e==_2b){return }if(_7e=="null"){_7e=""}_7e=_3b(_7e,true);if(_7e=="/"){_7e=""}if(_3a==_7e){return }_3a=_7e;_32=true;_48();_34[_h.length]=_3a;if(_21.isSafari()){if(_36.history){_l[_2c][_l.pathname]=_34.toString();_31=_h.length+1;if(_23<412){if(_l.search==""){_2e.action="#"+_3a;_2e.submit()}}else{if(_23<523){var evt=document.createEvent("MouseEvents");evt.initEvent("click",true,true);var _80=document.createElement("a");_80.href="#"+_3a;_80.dispatchEvent(evt)}else{_l.hash="#"+_3a}}}else{_l.replace("#"+_3a)}}else{if(_3a!=_37()){if(_36.history){_l.hash="#"+_3e(_3a)}else{_l.replace("#"+_3a)}}}if(_21.isIE()&&_36.history){if(_36.html){var loc=_2d.contentWindow.location;loc.assign(loc.pathname+"?"+_37())}else{_59()}}if(_21.isSafari()){_st(function(){_32=false},1)}else{_32=false}};this.getPath=function(){var _82=this.getValue();return(_82.indexOf("?")!=-1)?_82.split("?")[0]:_82};this.getPathNames=function(){var _83=SWFAddress.getPath();var _84=_83.split("/");if(_83.substr(0,1)=="/"){_84.splice(0,1)}if(_83.substr(_83.length-1,1)=="/"){_84.splice(_84.length-1,1)}return _84};this.getQueryString=function(){var _85=this.getValue();var _86=_85.indexOf("?");return(_86!=-1&&_86<_85.length)?_85.substr(_86+1):""};this.getParameter=function(_87){var _88=this.getValue();var _89=_88.indexOf("?");if(_89!=-1){_88=_88.substr(_89+1);var _8a=_88.split("&");var p,i=_8a.length;while(i--){p=_8a[i].split("=");if(p[0]==_87){return p[1]}}}return""};this.getParameterNames=function(){var _8d=this.getValue();var _8e=_8d.indexOf("?");var _8f=[];if(_8e!=-1){_8d=_8d.substr(_8e+1);if(_8d!=""&&_8d.indexOf("=")!=-1){var _90=_8d.split("&");var i=0;while(i<_90.length){_8f.push(_90[i].split("=")[0]);i++}}}return _8f};if(_24){for(var i=1;i<_31;i++){_34.push("")}_34.push(_37());if(_21.isIE()&&_l.hash!=_37()){_l.hash="#"+_3e(_37())}try{_2f=String(_40(document).src);var qi=_2f.indexOf("?");if(_2f&&qi>-1){var _94,_95=_2f.substr(qi+1).split("&");for(var i=0,p;p=_95[i];i++){_94=p.split("=");if(/^(history|html|strict)$/.test(_94[0])){_36[_94[0]]=(isNaN(_94[1])?eval(_94[1]):(parseFloat(_94[1])>0))}if(/^tracker$/.test(_94[0])){_36[_94[0]]=_94[1]}}}}catch(e){}if(/file:\/\//.test(_l.href)){_36.html=false}_45();_22.addListener(document,"DOMContentLoaded",_5e)}else{_55()}};new function(){var C,B;var A="undefined";if(typeof swfobject!=A){SWFObject=swfobject}if(typeof FlashObject!=A){SWFObject=FlashObject}if(typeof SWFObject!=A){if(SWFObject.prototype&&SWFObject.prototype.write){C=SWFObject.prototype.write;SWFObject.prototype.write=function(){B=arguments;if(this.getAttribute("version").major<8){this.addVariable("$swfaddress",SWFAddress.getValue());((typeof B[0]=="string")?document.getElementById(B[0]):B[0]).so=this}var D;if(D=C.apply(this,B)){SWFAddress.addId(this.getAttribute("id"))}return D}}else{C=SWFObject.registerObject;SWFObject.registerObject=function(){B=arguments;C.apply(this,B);SWFAddress.addId(B[0])};C=SWFObject.createSWF;SWFObject.createSWF=function(){B=arguments;C.apply(this,B);SWFAddress.addId(B[0].id)};C=SWFObject.embedSWF;SWFObject.embedSWF=function(){B=arguments;C.apply(this,B);SWFAddress.addId(B[8].id)}}}if(typeof UFO!=A){C=UFO.create;UFO.create=function(){B=arguments;C.apply(this,B);SWFAddress.addId(B[0].id)}}if(typeof AC_FL_RunContent!=A){C=AC_FL_RunContent;AC_FL_RunContent=function(){B=arguments;C.apply(this,B);for(var E=0,D=B.length;E<D;E++){if(B[E]=="id"){SWFAddress.addId(B[E+1])}}}}};

function Rand(n)
{
  return(Math.floor(Math.random() * n + 1));
}

function clearText(textBoxID)
{
  var textBoxObj = textBoxID;
  if((textBoxObj.value.indexOf("email address") != -1))
  {
    textBoxObj.value = "";
  }
}

function ShowDate(oDoc,cDate)
{
  window.open("datepicker.asp?backf="+oDoc+"&amp;cDate="+cDate, "DateWindow", "resizable=no,width=300,height=210");
}

function Change_Background(ImageNum)
{
  var NextImage = ImageNum + 1;
  if(NextImage == SlideshowImages.length)
  {
    NextImage = 0;
  }
  var LastImage = ImageNum - 1;
  if(LastImage == -1)
  {
    LastImage = SlideshowImages.length - 1;
  }

  $('#Background1').css("background", "url(" + SlideshowImages[LastImage] + ")");
  $('#Background2').css("background", "url(" + SlideshowImages[ImageNum] + ")");

  $('#Background1').fadeOut(1000, function() {
    $('#Background1').css("background", "url(" + SlideshowImages[ImageNum] + ")");
    $('#Background1').fadeIn(0, function() {$('#Background2').css("background", "url(" + SlideshowImages[NextImage] + ")");});
  });

  setTimeout("Change_Background(" + NextImage + ")", 4000);
}

var timer = 50;
var closetimer;
var currentmenu;

function open_menu(div)
{
  cancel_timer();
  close_menu();

 currentmenu = document.getElementById(div);
  $(currentmenu).slideDown(240);
}

function close_menu()
{
  if (currentmenu)
  {
    $(currentmenu).slideUp(0, null);
  }
}

function close_menu_ontimer()
{
  closetimer = window.setTimeout(close_menu, timer);
}

function cancel_timer()
{
  if (closetimer)
  {
    window.clearTimeout(closetimer);
  }
}

$(document).ready(function() {
  $('.down-list').width($('.dropdown-menu').width()-2);

  if((jQuery.browser.msie) && (parseInt(jQuery.browser.version) < 9))
  {
    $('.menu div a').width("154px");
  }

  $('.dropdown-menu').hover(
    function ()
    {
      $('.menu-first', this).addClass('slide-down');
      $('.down-list', this).slideDown(200);
    },
    function ()
    {
      obj = this;
      $('.down-list', this).slideUp(100, null);
      $('.menu-first', obj).removeClass('slide-down');
    }
  );
});

function SearchSubmit(SubmitURL)
{
  var LocalKeyword = $("#SearchText").val();
  if(LocalKeyword != "")
  {
    window.location = SubmitURL + "?IndexSearch=yes&KeywordSearch=true&Keyword=" + LocalKeyword;
  }
}

function SearchInput(SearchBox, Events, SubmitURL)
{
  var keycode;
  if(window.event)
  {
    keycode = window.event.keyCode;
  }
  else if (Events)
  {
    keycode = Events.which;
  }
  else
  {
    return true;
  }

  if(keycode == 13)
  {
    SearchSubmit(SubmitURL);
    return false;
  }
  else
  {
    return true;
  }
}

function Rotate_Callouts()
{
  CurrentTime = new Date();
  CurrentTimeMS = CurrentTime.getTime()
  if(Callouts_DeadTime < CurrentTimeMS)
  {
    var nextTab = "#tm" + (parseInt(Callouts_CurrentTab)+1);

    var activeTab = $(nextTab).find("a").attr("href"); //Find the rel attribute value to identify the active tab + content
    if(!activeTab)
    {
      nextTab = "#tm1";
      activeTab = $(nextTab).find("a").attr("href"); //Find the rel attribute value to identify the active tab + content
    }
    $("ul.calltabs li").removeClass("active"); //Remove any "active" class
    $(nextTab).addClass("active"); //Add "active" class to selected tab
    $(".calltab_content").hide(); //Hide all tab content
    $(activeTab).fadeIn(); //Fade in the active content
    Callouts_CurrentTab = activeTab.substring(8);
    Callouts_DeadTime = CurrentTimeMS + Callouts_WaitTime - 1;
    setTimeout("Rotate_Callouts();", Callouts_WaitTime);
  }
  else
  {
    setTimeout("Rotate_Callouts();", Callouts_DeadTime - CurrentTimeMS);
  }
}

function Init_Callouts()
{
  $(".calltab_content").hide(); //Hide all content
  $("ul.calltabs li:first").addClass("active").show(); //Activate first tab
  $(".calltab_content:first").show(); //Show first tab content
  
  $("ul.calltabs li").click(function() {
    var activeTab = $(this).find("a").attr("href"); //Find the rel attribute value to identify the active tab + content
    if(activeTab)
    {
      $("ul.calltabs li").removeClass("active"); //Remove any "active" class
      $(this).addClass("active"); //Add "active" class to selected tab
      $(".calltab_content").hide(); //Hide all tab content
      $(activeTab).fadeIn(); //Fade in the active content
      Callouts_CurrentTab = activeTab.substring(8);
      CurrentTime = new Date();
      Callouts_DeadTime = CurrentTime.getTime() + Callouts_WaitTime - 1;
    }
    return false;
  });

  setTimeout("Rotate_Callouts();", Callouts_WaitTime);
}

jQuery.cookie = function(name, value, options) {
    if (typeof value != 'undefined') { // name and value given, set cookie
        options = options || {};
        if (value === null) {
            value = '';
            options.expires = -1;
        }
        var expires = '';
        if (options.expires && (typeof options.expires == 'number' || options.expires.toUTCString)) {
            var date;
            if (typeof options.expires == 'number') {
                date = new Date();
                date.setTime(date.getTime() + (options.expires * 24 * 60 * 60 * 1000));
            } else {
                date = options.expires;
            }
            expires = '; expires=' + date.toUTCString(); // use expires attribute, max-age is not supported by IE
        }
        // CAUTION: Needed to parenthesize options.path and options.domain
        // in the following expressions, otherwise they evaluate to undefined
        // in the packed version for some reason...
        var path = options.path ? '; path=' + (options.path) : '';
        var domain = options.domain ? '; domain=' + (options.domain) : '';
        var secure = options.secure ? '; secure' : '';
        document.cookie = [name, '=', encodeURIComponent(value), expires, path, domain, secure].join('');
    } else { // only name given, get cookie
        var cookieValue = null;
        if (document.cookie && document.cookie != '') {
            var cookies = document.cookie.split(';');
            for (var i = 0; i < cookies.length; i++) {
                var cookie = jQuery.trim(cookies[i]);
                // Does this cookie string begin with the name we want?
                if (cookie.substring(0, name.length + 1) == (name + '=')) {
                    cookieValue = decodeURIComponent(cookie.substring(name.length + 1));
                    break;
                }
            }
        }
        return cookieValue;
    }
};

