

function validate_fields(theForm)
        {
                var strMessage, blnEmpty;
                strMessage = "Please enter the following fields: \n";
                blnEmpty = false;

                if(theForm.txtName.value == null || theForm.txtName.value == "")
                        { blnEmpty = true; strMessage = strMessage + " - Full Name\n"; }

                if(theForm.txtEmail.value == null || theForm.txtEmail.value == "" || !(isEmailAddr(theForm.txtEmail.value)))
                        { blnEmpty = true; strMessage = strMessage + " - Valid Email Address\n"; }

                if(theForm.txtMessage.value == null || theForm.txtMessage.value == "")
                        { blnEmpty = true; strMessage = strMessage + " - Your Message\n"; }


                if(blnEmpty)
                {  alert(strMessage); return (false); }
                else
                {  return (true); }
        }
		



function isEmailAddr(email)
{
	var result = false
	var theStr = new String(email)
	var index = theStr.indexOf("@");
	if (index > 0)
	{
		var pindex = theStr.indexOf(".",index);
		if ((pindex > index+1) && (theStr.length > pindex+1))
		result = true;
	}
	return result;
}



	function ShowLarge1(sUrl)
	{
		large_image1_win = window.open(sUrl, 'large_image1_win', 'width=650,height=450,scrollbars=yes,resizable=yes,status=no,location=no,menubar=no');
		large_image1_win.focus();
	}
