function submitAdd(form) {
	if (form.Description.value == "") {
		alert("Please describe your event.")
		form.Description.focus()
		form.Description.select()
		return false;
	}
	startIndex = form.stime.selectedIndex
	if (startIndex == 0) {
		alert("Please indicate when the event starts.")
		return false;
	}
	if (form.Name.value == "") {
		alert("You must enter your name.")
		form.Name.focus()
		form.Name.select()
		return false;
	}
	if (form.Email.value == "") {
		alert("Please provide your email address for.")
		form.Email.focus()
		form.Email.select()
		return false;
	}
	if (!validEmail(form.Email.value)) {
		alert("Invalid email address.")
		form.Email.focus()
		form.Email.select()
		return false;
	}
	return true;
}
function validEmail(email) {
	invalidChars = " /:,;"
// Empty is ok here, but if so we don't need to do more
	if (email == "") {
		return true;
	}
	for (i=0; i<invalidChars.length; i++) {
		badChar = invalidChars.charAt(i)
		if (email.indexOf(badChar,0) > -1) {
			return false;
		}
	}
	atPos = email.indexOf("@",1)
	if (atPos == -1) {
		return false;
	}
	if (email.indexOf("@",atPos+1) != -1) {
		return false;
	}
	periodPos = email.indexOf(".",atPos)
	if (periodPos == -1) {
		return false;
	}
	if (periodPos+3 > email.length) {
		return false;
	}
	return true;
}
function setStartIndex(form) {
	startIndex = form.stime.selectedIndex
	form.i_stime.value = startIndex
/*	alert("Start: "+form.i_stime.value)*/
}
function setEndIndex(form) {
	endIndex = form.etime.selectedIndex
	form.i_etime.value = endIndex
/*	alert("End: "+form.i_etime.value)*/
}