// Bak2Top v1.6 by MaxxBlade www.maxxblade.co.uk/bak2top

var b2tx=80,b2ty=50,b2th='<nobr>Back to Top</nobr>';
// Bak2Top v1.6 by MaxxBlade www.maxxblade.co.uk/bak2top

var ie6=document.documentElement;
if (document.documentElement) ie6=1;
function b2x(){
//if (moz) { return window.innerWidth-20-b2tx; }
//if (ie6) {return document.documentElement.clientWidth-b2tx;}
var dw = 0;
if (moz) { 
	dw = window.innerWidth-20-b2tx
//	if (dw > 800) {
//		dw = 820 + ((dw - 800) / 2);
//	}
	return dw; 
}
if (ie6) {
	dw = document.documentElement.clientWidth-b2tx
//	if (dw > 800) {
//		dw = 820 + ((dw - 800) / 2);
//	}
	return dw;
}

return document.body.clientWidth-b2tx;
}
function b2y(){
if (moz) { return window.innerHeight+b2o()-b2ty; }
if (ie6) {return document.documentElement.clientHeight +b2o()-b2ty;}
return document.body.clientHeight+b2o()-b2ty;
}
function b2o(){
if (moz) { return window.pageYOffset; }
if (ie6) {return document.documentElement.scrollTop;}
return document.body.scrollTop;
}
function b2t(){
if (document.layers) return;
 with(window.document.getElementById('bttl').style){
   left=((b2o()<1)?-500:b2x())+'px';
   top=((b2o()<1)?500:b2y())+'px';
 }
   setTimeout('b2t()',99);
}
var moz=(document.getElementById&&!document.all)?1:0; 
document.write('<div id="bttl" class="bak2top" style="position:absolute"><a style="cursor:'+((moz)?'pointer':'hand')+'" onclick="JavaScript:scrollTo(0,0)">'+b2th+'</a></div>');
b2t();