// JavaScript Document


$(document).ready(function() {
	
	
	$('ul#tab li').bind('click', function() {
		
		$('ul#tab li').removeClass('active').addClass('notactive');
		$(this).removeClass('notactive').addClass('active');
		var index = $('ul#tab li').index(this);
		
	});	
	
});


function Checkall()
{

	if((document.ContForm.fullname.value == "")||(document.ContForm.fullname.value == "Full Name"))
	{
		//alert("Please enter Your Name");
		document.getElementById('name_alert').style.display= 'block';
		document.getElementById('fullname').style.marginBottom='2px';
		document.ContForm.fullname.focus();
		return false;
	}
	else
	{
		document.getElementById('name_alert').style.display= 'none';
		document.getElementById('fullname').style.marginBottom='5px';
		}
	if((document.ContForm.company.value == "")||(document.ContForm.company.value == "Company Name"))
	{
		//alert("Please enter Your Name");
		document.getElementById('company_alert').style.display= 'block';
		document.getElementById('company').style.marginBottom='2px';
		document.ContForm.company.focus();
		return false;
	}
	else
	{
		document.getElementById('company_alert').style.display= 'none';
		document.getElementById('company').style.marginBottom='5px';
		}
	if((document.ContForm.designation.value == "")||(document.ContForm.designation.value == "Designation"))
	{
		//alert("Please enter Your Name");
		document.getElementById('desig_alert').style.display= 'block';
		document.getElementById('designation').style.marginBottom='2px';
		document.ContForm.designation.focus();
		return false;
	}
	else
	{
		document.getElementById('desig_alert').style.display= 'none';
		document.getElementById('designation').style.marginBottom='5px';
		}
	if(document.ContForm.service.value =="0")
    {
        //alert("Please select location.");
		document.getElementById('service_alert').style.display= 'block';
		document.getElementById('service').style.marginBottom='2px';
        document.ContForm.service.focus();
        return false;
    }
	else{
	 document.getElementById('service_alert').style.display= 'none';
		document.getElementById('service').style.marginBottom='5px';
	}
	if((document.ContForm.description.value == "")||(document.ContForm.description.value == "Description"))
	{
		//alert("Please enter Your Name");
		document.getElementById('desc_alert').style.display= 'block';
		document.getElementById('description').style.marginBottom='2px';
		document.ContForm.description.focus();
		return false;
	}
	else
	{
		document.getElementById('desc_alert').style.display= 'none';
		document.getElementById('description').style.marginBottom='5px';
		}
	if(document.ContForm.budget.value == "0")
    {
        //alert("Please select location.");
		document.getElementById('budget_alert').style.display= 'block';
		document.getElementById('budget').style.marginBottom='2px';
        document.ContForm.budget.focus();
        return false;
    }
	else{
	 document.getElementById('budget_alert').style.display= 'none';
		document.getElementById('budget').style.marginBottom='5px';
	}
	var regex = /^[\w\.\-]+@([\w\-]+\.)+[a-zA-Z]+$/;
	var email = document.ContForm.email.value;
	if((regex.test(email) == false)|| (document.ContForm.email.value == "")|| (document.ContForm.email.value == "Email Address"))
	{
		//alert("Please enter Valid Email ID");
		document.getElementById('email_alert').style.display= 'block';
		document.getElementById('email').style.marginBottom='2px';
		document.ContForm.email.focus();
		return false;
	}
	else{
	 document.getElementById('email_alert').style.display= 'none';
		document.getElementById('email').style.marginBottom='5px';
	}
	var regex = /[0-9]/;
	var code = document.ContForm.code.value;
	if((regex.test(code) == false) || (document.ContForm.code.value == "")|| (document.ContForm.code.value == "Country Code"))
	{
		//alert("Please enter Valid STD code");
		document.getElementById('code_alert').style.display= 'block';
		document.getElementById('code').style.marginBottom='2px';
		document.ContForm.code.focus();
		return false;
	}
	else{
	 	document.getElementById('code_alert').style.display= 'none';
		document.getElementById('code').style.marginBottom='2px';
	}
	var regex = /[0-9]/;
	var tel = document.ContForm.phone.value;
	if((regex.test(tel) == false) || (document.ContForm.phone.value == "")|| (document.ContForm.phone.value == "Phone Number"))
	{
		//alert("Please enter Valid STD code");
		document.getElementById('phone_alert').style.display= 'block';
		document.getElementById('phone').style.marginBottom='2px';
		document.ContForm.phone.focus();
		return false;
	}
	else{
	 	document.getElementById('phone_alert').style.display= 'none';
		document.getElementById('phone').style.marginBottom='5px';
	}
	
	if(document.ContForm.country.value =="0")
    {
        //alert("Please select location.");
		document.getElementById('country_alert').style.display= 'block';
		document.getElementById('country').style.marginBottom='2px';
        document.ContForm.country.focus();
        return false;
    }
	else{
	 document.getElementById('country_alert').style.display= 'none';
		document.getElementById('country').style.marginBottom='5px';
	}
}
