function submitForms()
{
 
if ( isFname() && isLname() && isDD() && isMM() && isYYYY() && isGender() && isMaritalStatus() && isAddress() && isCountry() && isphone() && isNationality() && isVisaStatus() && isExperience() && isSalary() && isCurrency() && isHowDidYouHear() && isCareerSummary() && isEmail() && validatePwd() && File1())
/*
if (confirm("\n Thank you !"))
{
//alert("\n Thank you !");
return true;
}
else
{
//alert("\n You have abort the submission.");
return false
}
*/
	return true;
else 
	return false;
}
function isEmail() {
if (document.Form1.Email.value == "") {
alert ("Enter Email")
return false;
}
if (document.Form1.Email.value.indexOf ('@',0) == -1 ||
document.Form1.Email.value.indexOf ('.',0) == -1) {
alert ("\n The E-mail Field requires a \"@\" and a \".\"be used. \n\nEnter Correct Email")

return false;
}
return true;
}
function isFname() 
{
if (document.Form1.FirstName.value == "")
{
alert ("Enter First Name")
return false;
}
return true;
}
function isLname()
 {
if (document.Form1.LastName.value == "") 
{
alert ("Enter Last Name")
return false;
}
return true;
}
function isAddress()
 {
if (document.Form1.Address.value == "")
 {
alert ("Enter Address")
return false;
}
return true;
}

function isCountry()
 {
 if ( document.Form1.Country.selectedIndex == 0 )
    {
        alert ("Select Country" );
        return false;
    }

return true;
} 
function isphone()
 {
if ( document.Form1.Phone.value=="" )
    {
        alert ("Enter Phone No" );
        return false;
    }

return true;

  }
 function isNationality()
 {
 if ( document.Form1.Nationality.selectedIndex == 0 )
    {
        alert ( "Select Nationality" );
        return false;
    }

return true;
}
  function isDD()
 {
 if ( document.Form1.DD.selectedIndex == 0 )
    {
        alert ( "Select Birth Date");
        return false;
    }

return true;
 }
   function isMM()
 {
 if ( document.Form1.MM.selectedIndex == 0 )
    {
        alert (  "Select Birth Date" );
        return false;
    }

return true;
}
    function isYYYY()
 {
 if ( document.Form1.YYYY.selectedIndex == 0 )
    {
        alert ( "Select Birth Date");
        return false;
    }

return true;
}
   function isGender()
 {
 if ( document.Form1.Gender.selectedIndex == 0 )
    {
        alert ( "Select Gender" );
        return false;
    }

return true;
}
   function isMaritalStatus()
 {
 if ( document.Form1.MaritalStatus.selectedIndex == 0 )
    {
        alert ( "Select Marital Status" );
        return false;
    }

return true;
}
   function isVisaStatus()
 {
 if ( document.Form1.VisaStatus.selectedIndex == 0 )
    {
        alert ( "Select Visa Status" );
        return false;
    }

return true;
}
function isExperience()
 {
 if ( document.Form1.Experience.selectedIndex < 0 )
    {
        alert ( " Select Experience" );
        return false;
    }

return true;
}
function isSalary() 
{
if (document.Form1.Salary.value=="") 
    {
        //if (event.keyCode < 48 || event.keyCode > 58) event.returnValue = false;"
		alert("Enter Expected Salary");
		return false;
	}
	return true;
}
// salary field accepts only numbers
function isSalaryNum(field)
{
var valid = "0123456789";
var ok = "yes";
var temp;
for (var i=0; i<field.value.length; i++){
	temp = "" + field.value.substring(i,i+1);
	if (valid.indexOf(temp) == "-1") ok = "no";
}
if (ok == "no"){
	alert("Invalid entry in salary field! Only numbers are accepted!");
	field.focus();
	field.select();
}
}

function isCurrency()
 {
 if ( document.Form1.Currency.selectedIndex < 0 )
    {
        alert ( "Select Currency" );
        return false;
    }

return true;
}
 function isHowDidYouHear()
 {
 if ( document.Form1.HowDidYouHear.selectedIndex == 0 )
    {
        alert ( "Select How did you hear about dulscojobs.");
        return false;
    }

return true;
  }
 function isCareerSummary()
 {
if (document.Form1.CareerSummary.value == "")
 {
alert ("Enter Career Summary")
return false;
}
return true;
}
function validatePwd() {
var invalid = " "; // Invalid character is a space
var minLength = 3; // Minimum length
var pw1 = document.Form1.Password.value;
var pw2 = document.Form1.ConfirmPassword.value;
// check for a value in both fields.
if (pw1 == '' || pw2 == '') {
alert('Enter password ');
return false;
}
// check for minimum length
if (document.Form1.Password.value.length < minLength) {
alert('Your password must be at least ' + minLength + ' characters long. Try again.');
return false;
}
// check for spaces
if (document.Form1.Password.value.indexOf(invalid) > -1) {
alert("Sorry, spaces are not Allowed.");
return false;
}
else {
if (pw1 != pw2) {
alert ("You did not enter the same new password twice.Please re-enter your password.");
return false;
}
else {
return true;
      }
   }
}
function File1() 
{
if (document.Form1.File1.value == "")
{
alert ("Pls. Upload Your Resume")
return false;
}
return true;
}
