    function validateForm()
    {
var eSimbol = new Array();
eSimbol[0] = '`'; eSimbol[1] = '~'; eSimbol[2] ='!'; eSimbol[3] = '#'; eSimbol[4] = '"'; eSimbol[5] = '№'; eSimbol[6] = '$'; eSimbol[7] =';';
eSimbol[8] = '%'; eSimbol[9] ='^'; eSimbol[10] = ':'; eSimbol[11] = '&'; eSimbol[12] = '?'; eSimbol[13] = '*'; eSimbol[14] = '(';
eSimbol[15] = ')'; eSimbol[17] = '+'; eSimbol[18] = '|'; eSimbol[19] = ' '; eSimbol[20] = '/'; eSimbol[21] = "'"; eSimbol[22] = '{';
eSimbol[23] = '}'; eSimbol[24] = '['; eSimbol[25] = ']'; eSimbol[26] = ','; eSimbol[27] = '<'; eSimbol[28] = ' >';  
		
		if (!document.getElementsByName('sex')[0].checked && !document.getElementsByName('sex')[1].checked)
		{
			alert("Please indicate your sex!");
			document.getElementById('sex').focus();
			return false;
		}		
		
		if (document.getElementById('name').value == "")
		{
			alert("You haven't entered contact person name!");
			document.getElementById('name').focus();
			return false;
		}		
		
		if (document.getElementById('surname').value == "")
		{
			alert("You haven't entered contact person surname!");
			document.getElementById('surname').focus();
			return false;
		}	
		
		if (document.getElementById('company_name').value == "")
		{
			alert("You haven't entered Company name!");
			document.getElementById('company_name').focus();
			return false;
		}	
		
		if (document.getElementById('country').value == "")
		{
			alert("You haven't chosen your country!");
			document.getElementById('country').focus();
			return false;
		}	
		
		if (document.getElementById('address').value == "")
		{
			alert("You haven't entered address!");
			document.getElementById('address').focus();
			return false;
		}	
		
		if (document.getElementById('phone').value == "")
		{
			alert("You haven't entered your phone number!");
			document.getElementById('phone').focus();
			return false;
		}		

			
		
		if (document.getElementById('e_mail').value == "")
		{
			alert("You haven't entered your E-mail address!");
			document.getElementById('e_mail').focus();
			return false;
		}
		else if (document.getElementById('e_mail').value.indexOf('@') == -1)
		{
			alert("Incorrect E-mail");
			document.getElementById('e_mail').focus();
			return false;
		}
		for(j= 0; j <= eSimbol.length - 1; j++)
		{	
			if (document.getElementById('e_mail').value.indexOf(eSimbol[j]) != -1)
			{
				
				alert("Incorrect E-mail");
				document.getElementById('e_mail').focus();
				return false;
			}
		}
		

		if (document.getElementById('kaptcha').value == "")
		{
			alert("Wrong key number!");
			document.getElementById('kaptcha').focus();
			return false;
		}	
		
		if(document.getElementById('questions').value == "")
		{
			alert("Please choose questions from the list or add your own!");
			document.getElementById('questions_button').click();
			return false;
		}
		
		document.product_interesting.submit();
				
		//Войтех А.Н. добавляем вставку, которая будет подписывать пациентов на рассылку
		if(document.getElementById('free_submit').checked){
			window.open('http://dotnews.ru/subscribe.php?id=eaca33e00ec184f6173aff429677b366&email=' + document.getElementById('e_mail').value, '_blank', 'height=290; width=420');
		}
		return true;
	}
	
function ShowPopUpWindow(URL)
{
	nw=window.open(URL, 'PopUp', 'scrollbars=yes,width=800,height=500,top=100,left=100,resizable=no,toolbar=no,location=no,menubar=no,status=0');
	nw.focus();
}
