$(document).ready(function($) {
	var lis = document.getElementById("navmenu-h").getElementsByTagName("LI");
	for (var i=0; i<lis.length; i++) {
		lis[i].onmouseover=function() {
			this.className+=" iehover";
		}
		lis[i].onmouseout=function() {
			this.className=this.className.replace(new RegExp("iehover\\b"), "");
		}
	}
	/*if (document.all && document.getElementById)
	{
		navRoot = document.getElementById("nav");
		for (i=0; i<navRoot.childNodes.length; i++)
		{
			node = navRoot.childNodes[i];
			if (node.nodeName=="LI")
			{
				node.onmouseover=function()
				{
					this.className+=" over";
				}
				node.onmouseout=function()
				{
					this.className=this.className.replace(" over", "");
				}
			}
		}
	}*/
});

function mark_error(id)
{
	$(id).addClass('error_field');
	$(id).removeClass('ok_field');
}
 
function unmark_error(id)
{
	$(id).addClass('ok_field');
	$(id).removeClass('error_field');
}

function checkEmail(value) {
	return value.match(/^[a-z0-9\-_-]+([\.%!][_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*$/);
}

function checkPhone(value) {
	return value.match(/^[0-9]{1,11}$/);
}
