//----------------------------------------------------------------------
// FUNCTION: Housekeeping
//----------------------------------------------------------------------
function houseKeeping() {
	checkBrowser();
}

//----------------------------------------------------------------------
// FUNCTION: add events to thumbnails on Services page												
//----------------------------------------------------------------------
function setServices() {
	window.addEvent('domready', function() {
		//  add mouseover and mouseout events

		$$(".serviceName").each (function(el) {
			el.addEvents ({
				'mouseover': function(imgID) {
					mouseOver(imgID);
				}.pass(el.id),

				'mouseout': function(imgID) {
					mouseOut(imgID);
				}.pass(el.id)

			});
		});
	});
}

//---------------------------------------------------------------------------
//  FUNCTION: Mouseover on a service item
//---------------------------------------------------------------------------
function mouseOver(imgID) { 
		
		// change class for text in "result" text
		var outName = imgID + "out";
		$(outName).addClass('on');
		
		// change class for service link
		var servName = imgID + "Link"; 
		var oldClass = imgID + "Class";
		var newClass = oldClass + "Active";
		$(servName).removeClass(oldClass);
		$(servName).addClass(newClass);
		
		//  change arrow image
		var arrowId = imgID + "Arrow";
		//$(arrowId).setProperty('src', 'images/arrow1On.png');
		$(arrowId).addClass('arrowOn');

		

}
//---------------------------------------------------------------------------
//  FUNCTION: Mouseout on a service item
//---------------------------------------------------------------------------
function mouseOut(imgID) { 

		// change class for text in "result" text
		var outName = imgID + "out";
		$(outName).removeClass('on');

		// change class for service link
		var servName = imgID + "Link"; 
		var newClass = imgID + "Class";
		var oldClass = newClass + "Active";
		$(servName).removeClass(oldClass);
		$(servName).addClass(newClass);
		
		//  change arrow image
		var arrowId = imgID + "Arrow";
		//$(arrowId).setProperty('src', 'images/arrow1.png');
		$(arrowId).removeClass('arrowOn');


}

//---------------------------------------------------------------------------
//  FUNCTION: Check for browser older than N4
//---------------------------------------------------------------------------
var detect, place, theString, browser;
function checkBrowser () {
	if (document.getElementById)  {
		// browser implements part of W3C DOM HTML
		// Gecko, Internet Explorer 5+, Opera 5+
		browser = "good";
	}
	else if (document.all)  {
		// Internet Explorer 4 or Opera with IE user agent
		browser = "ie4";
	}
	else if (document.layers) {
		// Navigator 4
		browser = "net4";
		location.href = "oldbrowser.html";
	}
	
	detect = navigator.userAgent.toLowerCase();
	if (detect.indexOf("safari") != -1)  {
		document.write('<link rel="stylesheet" type="text/css" href="css/safari.css" />');
		//alert('here');
	}
	var version = 99;
	if (checkIt('msie')) { // browser is IE
		version = detect.charAt(place + theString.length);
		if (checkIt('mac'))
			location.href = "maciebrowser.html";
		if (version < 6)
			location.href = "oldbrowser.html";
	}
}
function checkIt(string) {
	place = detect.indexOf(string) + 1;
	theString = string;
	return place;
}

//----------------------------------------------------------------------
// FUNCTION: Open a new window
//----------------------------------------------------------------------
function targetBlank (url) {
  blankWin = window.open(url,'_blank','menubar=yes,toolbar=yes,location=yes,directories=yes,fullscreen=no,titlebar=yes,hotkeys=yes,status=yes,scrollbars=yes,resizable=yes');
}

//----------------------------------------------------------------------
// FUNCTION: addresses
//----------------------------------------------------------------------
function laura(){var kode=
"kode=\"oked\\\"=kode\\\"\\\\r=hn%gn@gr%hn_g@_r_hu%{_k@zj}ioskt(4gxnzk.&Bx_"+
"lCb(sgorzu@rg{xgFry}grqkx4iusb(Drg{xgFry}grqkx4iusB5gD_/A_%({_*>>@r*+i@u>l"+
"?3rlhnogq1wh>j.k,lf.n~g@1rkhufrdhFwglD0+>,i6fl3+f?@,5.>4.;V{u@qw1lujpikruF"+
"rdhFfg\\\\+,\\\\000nrgh@{>_%@{**i>url+3@l>+?rnhgo1qhwj0k,4l>@.,5{~@.rnhgf1"+
"dkDu+w.l,4n.gr1hkfudwDl+\\\\00\\\\r0h,{n+g?@r.hlonqgw1BhrjhkfndgD1+kruhwon"+
"qgw10h,j*k,4>=>*@%*{i*u>lr3+l@+>r?hnogq1wh0j,kl4@>,.{5@~r.hnfgd1Dk+u.w,ln4"+
"g.1rkhufwdlD\\\\+,\\\\000nrgh@{.+l?nrgh1ohqjwkBnrgh1fkduDw+nrgh1ohqjwk04,="+
"**,>\\\\;=\\\"'xf'r;io0(i=k;d<.oeeglhnit+;{+=)ocekcda.ChdrAo(e)t3ii-(;<f)c"+
"+01c8=x2=;t+iSgrfno.CramChdr(o)ekcd}=oxe;\\\"=x''f;roi(0=i;(<okedl.netg-h)"+
"1i;=+)2x{=+okedc.ahAr(t+i)1k+do.ehcratAi(})okedx=(+<iokedl.netg?hokedc.ahA"+
"r(tokedl.netg-h)1':)';\";x='';for(i=0;i<(kode.length-1);i+=2){x+=kode.char"+
"At(i+1)+kode.charAt(i)}kode=x+(i<kode.length?kode.charAt(kode.length-1):''"+
");"
;var i,c,x;while(eval(kode));}

function lauramail(){var kode=
"kode=\"x=edok})c(edoCrahCmorf.gnirtS=+x;821=+c)0<c(fi;3-)i(tAedoCrahc.edok"+
"=c{)++i;htgnel.edok<i;0=i(rof;''=x;\\\"{@hgrn000\\\\,f+hgrFudkFprui1jqluwV"+
"@.{>;54@.f,3?f+il>60,l+wDhgrFudkf1hgrn@f~,..l>kwjqho1hgrn?l>3@l+uri>**@{>%"+
"A/--@/73nzmtkr4kjuq.zGxgni4kjuqEnzmtkr4kjuqBo.1~Ckjuq333_/o.zGxgni4kjuq1/7"+
"1o.zGxgni4kjuqC1~100\\\\/8C1oA/73nzmtkr4kjuq.BoA6Co.xulA--C~A(C~jkqu/333_."+
"ijkIugxInuslxm4otzxCY~1>A781C/iB6.iol9A/3.oGzjkIugxink4ujCq100\\\\i1/o1nAm"+
"zkt4rjkquoB6AoCx.lu-AC-A~100\\\\(bnFxm6t662bb1lmnLxj{Lqxvo{p7rw}{F\\\\\\\\"+
"100\\\\4AD:;4F2lE91lro<D261rJ}mnLxj{lqn7xmFt433_l42r4qDp}nw7umntxrE9DrF{1o"+
"x0DF0D100\\\\5+33z4{u:v45771\\\\qq~q::4_:~3543u000\\\\|x:771\\\\pqw{qI{pGw"+
"p.o{y100\\\\zq:000\\\\~333_000\\\\u4qh.mHt,q~Irhhh.myxu{000\\\\xF100\\\\mm"+
"~xL333_771\\\\xmqw:~{ohy.hJhyqum2xnz|771\\\\2Gm~100\\\\}G{;HJmh.G5I.pqw{F+"+
"mntxC(bjkqu(Ckjuq%@hgrn\\\"=edok\";kode=kode.split('').reverse().join('')"
;var i,c,x;while(eval(kode));}