function validate(form) {
	if(form.hypo_dam.value == '') {
		alert('Dam\'s name is required.');
		form.hypo_dam.focus();
		return false;
	}
}
function clearEmail() {
	document.getElementById("email").value="";
}

// When the DOM is ready, initialize the scripts.
jQuery(function($) {
	var container = $("#enews-signup-form");
	// Bind the link to toggle the slide.
	$("#enews-signup-form-toggle").click(function(event) {
		// Prevent the default event.
		event.preventDefault();
		// Toggle the slide based on its current visibility.
		if (container.is(":visible")) {
			// Hide - slide up.
			container.slideUp( 250 );
		} else {
			// Show - slide down.
			container.slideDown( 250 );
		}
	}
	);
});
jQuery(function($) {
	var container2 = $("#navigation-left-news");
	// Bind the link to toggle the slide.
	$("#navigation-left-news-toggle").click(function(event) {
		// Prevent the default event.
		event.preventDefault();
		// Toggle the slide based on its current visibility.
		if (container2.is(":visible")) {
			// Hide - slide up.
			container2.slideUp( 250 );
			return false;
		} else {
			// Show - slide down.
			container2.slideDown( 250 );
			return false;
		}
	}
	);
});
function custWindow(doc,w,h,align,valign,scroll) {
	if (custWindow.arguments.length < 6) {
		var scroll = 'yes'
		}
	if (custWindow.arguments.length < 4) {
		var align = 'c'
		var valign = 'm'
		}
	topPos=0
	leftPos=0
	if (screen) {
		if (align == 'c') {
			leftPos = screen.width/2 - w/2
			} else {
			if (align == 'r') {
				leftPos = screen.width - w - 12
				}
			}
		if (valign == 'm') {
			topPos = screen.height/2 - h/2
			} else {
			if (valign == 'b') {
				topPos = screen.height - h - 45
				}
			}
		}
	custWin = window.open (doc,'custWin','toolbar=no,location=no,scrollbars='+scroll+',resizable=yes,width='+w+',height='+h+',left='+leftPos+',top='+topPos+'')
	custWin.document.close()
	custWin.focus()	
}
