function go(to) {
	if (isNaN(to)) {
		i = 0;
		while (to.indexOf("&amp;") >= 0) {
			
			to = to.replace("&amp;","&");
			i++;
		}
		document.location.href=to;
	}else{
		history.back(to);
	}
}
function obj(id) {

    return document.getElementById(id);
}
function out(text) {
	document.write(text);
}
function clear(id) {
	if (typeof(id) == "string" || typeof(id) == "number") {
		obj = document.getElementById(id);
		if (obj != undefined) {
			while (this.obj.childNodes.length) {
				this.obj.removeChild(this.obj.childNodes[0]);
			}
		}
		return true;
	}
	if (typeof(id) == "object") {
		obj = id;
		while (this.obj.childNodes.length) {
			this.obj.removeChild(this.obj.childNodes[0]);
		}
		return true;
	}
	return false;
}
function moveChildren(from,to) {
	if (typeof(from) == "string" || typeof(from) == "number") {
		if (document.getElementById(from) != undefined) {
			from_obj = document.getElementById(from);
		}
	}
	if (typeof(to) == "object") {
		from_obj = to;
	}
	
	if (typeof(to) == "string" || typeof(to) == "number") {
		if (document.getElementById(to) != undefined) {
			to_obj = document.getElementById(to);
		}
	}
	if (typeof(to) == "object") {
		to_obj = to;
	}
	if (typeof(from_object) == "object" || typeof(to_object) == "object") {
		
	}
}
/**
* A datastructure that contains objects
*/
function HxObjectList() {
	//Variables
	this.objects			= new Array();
	this.i					= 0;
	this.cur				= undefined;
	//Functions
	this.addObject 			= HxObjectList_addObject;
	this.getObject			= HxObjectList_getObject;
	this.forward			= HxObjectList_forward;
	this.backward			= HxObjectList_backward;
	this.count				= HxObjectList_countObjects;
	this.first				= HxObjectList_first;
	this.last				= HxObjectList_last;
}
function HxObjectList_addObject(obj) {
	c = this.objects.length;
	var newArray = new Array(c+1);
	for (i=0;i<c;i++) {
		newArray[i] = this.objects[i];
	}
	this.cur = obj;
	newArray[c] = obj;
	this.objects = newArray;
}
function HxObjectList_getObject() {
	if (i != undefined) {
		if (i < this.count()) {
			this.i = i;
			this.cur = this.objects[this.i];
			return true;
		}
		return undefined;
	} else {
		return this.cur;
	}
}
function HxObjectList_getObject(i) {
	if (i != undefined) {
		if (i < this.count()) {
			this.i = i;
			this.cur = this.objects[this.i];
			return true;
		}
		return undefined;
	} else {
		return this.cur;
	}
}
function HxObjectList_first() {
	this.i = 0;	
	this.cur = this.objects[this.i];
}
function HxObjectList_last() {
	this.i = this.count()-1;	
	this.cur = this.objects[this.i];
}
function HxObjectList_forward() {
	if (this.i+1 < this.objects.length) {
		this.i++;
		this.cur = this.objects[this.i];
		return this.cur;
	} else {
		this.cur = undefined;
		return false;
	}
}
function HxObjectList_backward() {
	if (this.i-1 >= 0) {
		this.i--;
		this.cur = this.objects[this.i];
		return this.cur;
	} else {
		this.cur = undefined;
		return false;
	}
}
function HxObjectList_countObjects() {
	return this.objects.length;
}

function HxCookie() {
	this.setCookie = HxCookie_setCookie;
	this.getCookie = HxCookie_getCookie;
	this.parseCookie = HxCookie_cookieParseCookie;
	this.resemble = HxCookie_cookieResemble;
	this.parseCookie();
}
function HxCookie_setCookie(key,val,expiredays) {
	var exdate=new Date()
	exdate.setDate(expiredays)
    str = new String(document.cookie);
    if (str.substr(str.length-1,1) != ";") {
	    document.cookie=";"+key+ "=" +escape(val)+ ((expiredays==null) ? "" : ";expires="+exdate)+";";document.cookie=";";
    } else {
        document.cookie=key+ "=" +escape(val)+ ((expiredays==null) ? "" : ";expires="+exdate)+";";
    }
    document.cookie = key+"="+val+";";
}

function HxCookie_getCookie(key) {
	if (document.cookie.length>0) {
		c_start=document.cookie.indexOf(key + "=")
		if (c_start!=-1) { 
			c_start=c_start + key.length+1 
			c_end=document.cookie.indexOf(";",c_start)
			if (c_end==-1) 
				c_end=document.cookie.length
			return unescape(document.cookie.substring(c_start,c_end))
		} 
	}
	return null
}
function HxCookie_cookieParseCookie() {
}
function HxCookie_cookieResemble() {
}