/*<script>*/
	/* Version 1.3.3 / 2003-01-30 / David M?rtensson*/
	/* Copyright David M?rtensson/Multinet Holding AB - 2000-2003 */
	/* some parts like the bw function is derived from the work of www.bratta.com */
	/* Version 1.3.4 / 2003-10-17 / David M?rtensson */
	/* - Code cleanup, changed some code that casued warnings in Mozilla javascript console */

	function getbw(){ return new _bw(); }
	function _bw(){
		this.ver=navigator.appVersion;
		this.name=navigator.appName;
		this.dom=document.getElementById?1:0;
		this.ua=navigator.userAgent;
		this.all=typeof( document["all"] ) != "undefined";
		this.layes=typeof( document["layers"] ) != "undefined";	
		this.ie= this.ver.indexOf("MSIE")>-1;
		this.moz= this.ua.indexOf("Gecko")>-1;
		this.opera= this.ua.indexOf("Opera")>-1;
		this.safari= this.ua.indexOf("safari")>-1;
		this.ie4=(this.ie&&parseInt(this.ver.substr(this.ver.indexOf("MSIE")+5,4))==4)?1:0;
		this.ie50=(this.ie&&parseInt(this.ver.substr(this.ver.indexOf("MSIE")+5,4))==5)?1:0;
		this.ie5=(this.ie&&parseInt(this.ver.substr(this.ver.indexOf("MSIE")+5,4))>=5)?1:0;
		this.ie6=(this.ie&&parseInt(this.ver.substr(this.ver.indexOf("MSIE")+5,4))>=6)?1:0;
		this.ns5=((!this.ie)&&this.dom&&parseInt(this.ver) >= 5)?1:0; 
		this.ns4=this.ns5?0:(this.layers && !this.dom)?1:0;
		this.ns=(this.ns4||this.ns5);
		this.style=(this.ie||this.ns5);
		this.bw=(this.ie5||this.ie4||this.ns4||this.ns5)
		this.test = bw_test;
		return this
	}
	var bw = getbw();	
	
	function bw_test()
	{
		document.write ( "ver: " + this.ver + "\n<br>" )
		document.write ( "name: " + this.name + "\n<br>" )
		document.write ( "dom: " + this.dom + "\n<br>" )
		document.write ( "all: " + this.all + "\n<br>" )
		document.write ( "layers: " + this.layers + "\n<br>" )
		document.write ( "ua: " + this.ua + "\n<br>" )
		document.write ( "ie: " + this.ie + "\n<br>" )
		document.write ( "moz: " + this.moz + "\n<br>" )
		document.write ( "opera: " + this.opera + "\n<br>" )
		document.write ( "safari: " + this.safari + "\n<br>" )
		document.write ( "ie5: " + this.ie5 + "\n<br>" )
		document.write ( "ie50: " + this.ie50 + "\n<br>" )
		document.write ( "ns5: " + this.ns5 + "\n<br>" )
		document.write ( "ns4: " + this.ns4 + "\n<br>" )
		document.write ( "ns: " + this.ns + "\n<br>" )
		document.write ( "style: " + this.style + "\n<br>" )
		document.write ( "bw: " + this.bw + "\n<br>" )
	}
			
	function getObjByID(id) { return bw.dom?document.getElementById(id):bw.all?document.all[id]:bw.layers?document.layers[id]:null; }
	function getObjByTagName(name) { return bw.dom?document.body.getElementsByTagName(name):bw.all?document.body.all.tags(name):bw.layers?document.layers[id]:null; }

	function getOffsetTop(_obj) { if(bw.ie||bw.ns5) if(typeof(_obj) == "object" && _obj != null && _obj.tagName != "body") return getOffsetTop(_obj.offsetParent) + _obj.offsetTop; return 0; }
	function getOffsetLeft(_obj) { if(bw.ie||bw.ns5) if(typeof(_obj) == "object" && _obj != null && _obj.tagName != "body") return getOffsetLeft(_obj.offsetParent) + _obj.offsetLeft; return 0; }
	function getOffsetWidth(_obj) { if(bw.ie||bw.ns5) return _obj.offsetWidth; return 0; }
	function getOffsetHeight(_obj) { if(bw.ie||bw.ns5) return _obj.offsetHeight; return 0; }
	function hideSelects() 
	{ 
		if(!bw.ie) 
			return 0;
		var selects = count = 0;
		if( ( selects = getObjByTagName("SELECT") ) != null )
			for(;count < selects.length; count++) { selects[count].style.visibility = "hidden"; }
		return 0;
	}
	function showSelects() 
	{ 
		if(!bw.ie) 
			return 0;
		var selects = count = 0;
		if( ( selects = getObjByTagName("SELECT") ) != null )
			for(;count < selects.length; count++) { selects[count].style.visibility = "visible"; }
		return 0;
	}
	
/*** Layer kod ***/
	function lyr(id, ver) { return new _lyr(id); }
	function _lyr(id) {
		this.id = id;
		this.lyr = getObjByID(id);
		if( this.lyr != null )
		{
			this.css = bw.style?this.lyr.style:this.lyr;
			this.isvisible = this.css.visibility == bw.ns4?"show":"visible";

			this.left = _left;
			this.top = _top;
			this.width = _width;
			this.height = _height;
					
			this.show = _show;	
			this.hide = _hide; 
			this.write = _write; 
			this.moveto = _moveto; 
			this.sizeto = _sizeto;
			this.display = _display; 
			this.remove = _remove;
			this.alignto = _alignto;
			this.inline = _inline; 
			this.block = _block;
			this.opacity = _opacity;
			this.fadeto = _fadeto;
			this.exists = true;
		} else {
			this.exists = false;
		}
				
		return this;
	}
	function _left() { return getOffsetLeft(this.lyr)||0; }
	function _top() { return getOffsetTop(this.lyr)||0; }
	function _width() { return getOffsetWidth(this.lyr)||0; }
	function _height() { return getOffsetHeight(this.lyr)||0; }
	function _show(z) { this.css.visibility = (bw.ns4)?"show":"visible"; if(!isNaN(z)) this.css.zIndex = z; this.isvisible = 1; return 0; }
	function _hide(z) { this.css.visibility = (bw.ns4)?"hide":"hidden"; if(!isNaN(z)) this.css.zIndex = z; this.isvisible = 0; return 0; }
	function _display(t) { if(!bw.ns4) this.css.display = isNaN(t)?"block":"inline"; return 0; }
	function _inline(z) { if(!bw.ns4) { this.css.zIndex = z; this.css.display = "inline"; } return 0; }
	function _block(z) { if(!bw.ns4) { this.css.zIndex = z; this.css.display = "block"; } return 0; }
	function _remove() { if(!bw.ns4) this.css.display = "none"; return 0; }
	function _write(s) { if(bw.ns4) { this.lyr.document.write(s); this.lyr.document.close(); } else this.lyr.innerHTML = s; return 0; }
	function _moveto(x,y) { this.css.left = x+"px"; this.css.top = y+"px"; return 0; }
	function _slideto(x,y,z,d) { return 0;}	//Stegvis f?rflyttning (x,y [,z [,d] ] )
	function _growto(x,y,z,d) { return 0;}	//Stegvis storleksf?r?ndring (x,y [,z [,d] ] )
	function _sizeto(x,y) { this.css.width = x+"px"; this.css.height = y+"px"; return 0; }
	function _alignto(id, pos) { 
		var _obj = new _lyr(id);
		var i, ypos, xpos;
		if( typeof(pos) == "undefined" ) pos = "b,lo";
		apos = pos.split(",");
		for( i=0; i < apos.length; i++ )
			switch( apos[i] ) {
				case "b": ypos = _obj.top() + _obj.height(); break;
				case "bo": ypos = _obj.top() + _obj.height() - this.height(); break;
				case "l": xpos = _obj.left() - this.width(); break;
				case "lo": xpos = _obj.left(); break;
				case "r":  xpos = _obj.left() + _obj.width(); break;
				case "ro": xpos = _obj.left() + _obj.width() - this.width(); break;
				case "t": ypos = _obj.top(); break;
				case "to": ypos = _obj.top() - this.height(); break;
				case "xc": xpos = _obj.left() + ((_obj.width - _obj.left()) / 2) - (this.width() / 2);
				case "yc": ypos = _obj.top() + ((_obj.height - _obj.top()) / 2) - (this.height() / 2);
			}
		if( typeof( xpos ) == "undefined" ) xpos = _obj.left();
		if( typeof( ypos ) == "undefined" ) ypos = _obj.top() + _obj.height();
		this.moveto(xpos, ypos);
		return 0;
	}
	function _opacity(a) { 
		if(typeof(a) == "undefined")
		{
			if(this.css.filter == "") this.css.filter = "Alpha(Opacity=100)";
			
			return bw.ie?this.lyr.filters.alpha.opacity:(bw.ns5)?this.css.MozOpacity*100:null;
		}
		else
		{
			if(bw.ie) {
				if(String(this.css.filter).indexOf("Alpha") == -1)
					this.css.filter = "Alpha(Opacity=" + a + ")";
				else
				{
					this.lyr.filters.alpha.enabled = 1; 
					this.lyr.filters.alpha.opacity = a;
				}
			} else
				if(bw.ns5) 
					this.css.MozOpacity=a/100; 
		}
		return 0;
	}
	function _fadeto(a, b, t) {
		if(typeof(b) != "number") 
			b = this.opacity();
		else
			this.opacity(b);
		if(typeof(t) == "undefined") t = 50;
		setTimeout("lyr(" + this.id + ").fadeto("+a+","+(b<a)?b+1:b-1+","+t+")", t);
		return 0;
	}
			
	
	function frm(name) { return bw.ns?eval("document."+name):eval(name); }
	
	function element(id) { return getObjByID( id ); }
	function tags(name) { return getObjByTagName( name ); }
	
	var compdoc = bw.ie4||bw.ie5?window:document;
	
/*
	
	if (( Array.prototype.push && ([0].push(true)==true)))
		Array.prototype.push = null;
		
	if(!Array.prototype.push)
	{
		function array_push() {
		    for(i=0;i<arguments.length;i++){
		        this[this.length] = arguments[i];
		    }
		    return this.length;
		}
	    Array.prototype.push = array_push;
	}

	if(!Array.prototype.pop) {

	    function array_pop(){
	        lastElement = this[this.length-1];
	        this.length = Math.max(this.length-1,0);
	        return lastElement;
	    }

	    Array.prototype.pop = array_pop;

	}
	
	if(Array.prototype.splice && typeof([0].splice(0))=="number")
	    Array.prototype.splice = null;

	if(!Array.prototype.splice) {

	    function array_splice(ind,cnt){
	        if(arguments.length == 0) return ind;
	        if(typeof ind != "number") ind = 0;
	        if(ind < 0) ind = Math.max(0,this.length + ind);
	        if(ind > this.length) {
	            if(arguments.length > 2) ind = this.length;
	            else return [];
	        }
	        if(arguments.length < 2) cnt = this.length-ind;
	        cnt = (typeof cnt == "number") ? Math.max(0,cnt) : 0;
	        removeArray = this.slice(ind,ind+cnt);
	        endArray = this.slice(ind+cnt);
	        this.length = ind;
	        for(var i=2;i<arguments.length;i++){
	            this[this.length] = arguments[i];
	        }
	        for(var i=0;i<endArray.length;i++){
	            this[this.length] = endArray[i];
	        }
	        return removeArray;
	    }

	    Array.prototype.splice = array_splice;
	}

*/