var dir = "/"
function remember() {
	var x=document.forms.login
	if(x[3].checked) {
		x[3].checked=false
	} else {
		x[3].checked=true
	}
}

function checkbox(form, fieldname, value)
{
	if(!document.forms[form])
		return;
	var objCheckBoxes = document.forms[form].elements[fieldname];
	if(!objCheckBoxes)
		return;
	var countCheckBoxes = objCheckBoxes.length;
	if(!countCheckBoxes)
		objCheckBoxes.checked = value;
	else
		// set the check value for all check boxes
		for(var i = 0; i < countCheckBoxes; i++)
			objCheckBoxes[i].checked = value;
}

function flip(rid) {
	current=(document.getElementById(rid).style.display == 'none') ? 'block' : 'none'
	document.getElementById(rid).style.display = current
}

function link(id) {
	switch(id) {
		case 1:
			window.location = "http://" + window.location.hostname + dir + "news/"
			break
		case 2:
			window.location = "http://" + window.location.hostname + dir + "/"
			break
		case 3:
			window.location = "http://" + window.location.hostname + dir + "poll/"
			break
		case 4:
			window.location = "http://" + window.location.hostname + dir + "forum/"
			break
		case 5:
			window.location = "http://" + window.location.hostname + dir + "sponsors/"
			break
		case 6:
			window.location = "http://" + window.location.hostname + dir + "contacts/"
			break
		default:
			break	
	}
}

