/**********************************************
	VYOM AJAX PROCESSOR
	(c) Vyom Technosoft Pvt. Ltd.
	Author - Amit Mathur, 18 Jun 2006

	Unauthorised copying or distribution is
	prohibited.
	***********************************************/

function vyomAJAXProcessor(strURL,divName)
{
	var xmlHttpReq = false;
	var self = this;
	// Mozilla/Safari
	if (window.XMLHttpRequest) {
		self.xmlHttpReq = new XMLHttpRequest();
	}
	// IE
	else if (window.ActiveXObject) {
		self.xmlHttpReq = new ActiveXObject("Microsoft.XMLHTTP");
	}
	self.xmlHttpReq.open('POST', strURL, true);
	self.xmlHttpReq.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded');
	self.xmlHttpReq.onreadystatechange = function() {
		if (self.xmlHttpReq.readyState == 4) {
			updatepage(self.xmlHttpReq.responseText,divName);
		}
	}
	self.xmlHttpReq.send(strURL);
}
	
function vyomAJAXCities(value)
{		
	if (value == 0)
	{
		updatepage("<font class='smalltext'> Retrieving Cities...</font>","cityList");
		strURL = "getCities.asp?id=" + value;
		vyomAJAXProcessor(strURL,"cityList");
	}
}

	
function updatepage(str,divName){
	document.getElementById(divName).innerHTML = str;
}

function date(xxxxx) {
	 var maintainplus = '';
 	var numval = xxxxx.value
 	if ( numval.charAt(0)=='+' ){ var maintainplus = '+';}
 	curphonevar = numval.replace(/[\\A-Za-z!"£$%^&*+_={};:'@#~,.¦\/<>?|`¬\]\[]/g,'');
 	xxxxx.value = maintainplus + curphonevar;
 	var maintainplus = '';
 	xxxxx.focus;
}

//***********************displaying read message*****************

function vyomAJAXPreProcessorForugSpecilisation(value)
{    	
	
	if(value==0) 
	{
		divName = "result";
	}
	else
	{
		divName = "result" + value;
    }
	updatepage("<font face=verdana size=1 color=black>Please wait; loading ....</font>",divName);
	strURL = "/candidates/ugSpecilisation-ajax.asp?name=" + document.forms['frmUserRegistrationqualification'].ugQualification.value;
	vyomAJAXProcessor(strURL,"result");
}


function vyomAJAXPreProcessorForpgSpecilisation(value)
{    
	
	if(value==0) 
	{
		divName = "result2";
	}
	else
	{
		divName = "result2" + value;
    }
	
	updatepage("<font face=verdana size=1 color=black>Please wait; loading ....</font>",divName);
	strURL = "/candidates/pgSpecilisation-ajax.asp?name2=" + document.forms['frmUserRegistrationqualification'].pgQualification.value;
	vyomAJAXProcessor(strURL,"result2");
}

function vyomAJAXPreProcessorForpostpgSpecilisation(value)
{    	
	if(value==0) 
	{
		divName = "result3";
	}
	else
	{
		divName = "result3" + value;
    }	
	updatepage("<font face=verdana size=1 color=black>Please wait; loading ....</font>",divName);
	strURL = "/candidates/postpgSpecilisation-ajax.asp?name3=" + document.forms['frmUserRegistrationqualification'].masterQualification.value;
	vyomAJAXProcessor(strURL,"result3");
}

function vyomAjaxLatestNews()
{
	updatepage("<img src='/backup/gui/images/loading.gif'>","countrydivcontainer")
	strURL = "/news/getLatestNews.asp"
	vyomAJAXProcessor(strURL,"countrydivcontainer")
}

function vyomAjaxCompanyNews()
{
	updatepage("<img src='/backup/gui/images/loading.gif'>","countrydivcontainer")
	strURL = "/news/getCompanyNews.asp"
	vyomAJAXProcessor(strURL,"countrydivcontainer")
}

function vyomAjaxIndustryNews()
{
	updatepage("<img src='/backup/gui/images/loading.gif'>","countrydivcontainer")
	strURL = "/news/getIndustryNews.asp"
	vyomAJAXProcessor(strURL,"countrydivcontainer")
}

function vyomAjaxJobTypeNews()
{
	updatepage("<img src='/backup/gui/images/loading.gif'>","countrydivcontainer")
	strURL = "/news/getJobTypeNews.asp"
	vyomAJAXProcessor(strURL,"countrydivcontainer")	
}
function selectCollegeName()
{
 id = document.forms['registerFrm'].collegeName.value
 updatepage("<img src='/backup/gui/images/loading.gif'>","college")
 strURL = "/colleges/getCollegeName.asp?CollegeId="+id ;
 vyomAJAXProcessor(strURL,"college")	
}
function vyomAJAXPreProcessorForpostpgSpecilisationProfile(value)
{    	
	divName = "result3";	
	updatepage("<font face=verdana size=1 color=black>Please wait; loading ....</font>",divName);
	strURL = "/candidates/postpgSpecilisation-ajax.asp?name3=" + document.forms['profile'].masterQualification.value;
	vyomAJAXProcessor(strURL,"result3");
}

	
var folders
folders="";
function VYOMAJAXCreatefolder(str)
{
	if (str)
	{
		folders = str
	}
	else
	{
		if (folders=="/")
		{
			folders = ""
		}
		folders=folders+"/"+document.forms['frm'].foldersName.value;
	}
	updatepage("<font face=verdana size=1 color=black>Please wait....</font>","divFolderes");
	updatepage("<input type='text' name = 'folderPath' size='45' value="+folders+">","divFolderess");
	strURL = "/ad-min/folders/getSubfolderes.asp?id=" + folders;
	vyomAJAXProcessor(strURL,"divFolderes");
}


var folder
folder="";
	
function VYOMAJAXfolder(str)
{
	if (str)
	{
		folder = str
	}
	else
	{
		if (folder=="/")
		{
			folder = ""
		}
		folder=folder+"/"+document.forms['frm'].folderName.value;
	}
		
	updatepage("<font face=verdana size=1 color=black>Please wait....</font>","divFolder");
	updatepage("<input type='text' name = 'folderPath' size='45' value="+folder+">","divFolders");
	strURL = "/ad-min/folders/getSubfolders.asp?id=" + folder;
	vyomAJAXProcessor(strURL,"divFolder");
}

function showProfileAjax()
{
    updatepage("<IMG SRC='/images/loading1.gif'>","showProfile");
	strURL = "/candidates/viewProfile_ajax.asp?id="+ document.forms['profile'].showProfile.value;
	vyomAJAXProcessor(strURL,"showProfile");
}
function vyomAJAXRegister()
{	 
	updatepage("<IMG SRC='/images/loading1.gif'>","result1");
	strURL = "/candidates/getCountryRegistration.asp?id=" + document.forms['frmUserRegistration'].cmbCountry.value;
	vyomAJAXProcessor(strURL,"result1");
}
function vyomAJAXRegisterCity()
{	 
	updatepage("<IMG SRC='/images/loading1.gif'>","result1");
	strURL = "/candidates/getCountryCityRegistration.asp?id=" + document.forms['frmUserRegistration'].subCategory.value;
	vyomAJAXProcessor(strURL,"result1");
}

function vyomAJAXMonth()
{
	
	x=parseInt(document.forms['resumeSubmitter'].months.value);
	strURL = "/resume-submitter/resume.asp?id="+ x;
	vyomAJAXProcessor(strURL,"total");
	
}

function vyomAJAXDomestic()
{
	x=parseInt(document.forms['resumeSubmitter'].domestic.value);
	strURL = "/resume-submitter/resume.asp?id=" + x;
	vyomAJAXProcessor(strURL,"total");
}

function vyomAJAXGulf()
{
	x=parseInt(document.forms['resumeSubmitter'].gulf.value);
	strURL = "/resume-submitter/resume.asp?id=" + x;
	vyomAJAXProcessor(strURL,"total");
}

function vyomAJAXQualification()
{
	updatepage("<IMG SRC='/images/loading1.gif'>","result5");
	strURL = "/getQualification.asp?id=" + document.forms['frmUserRegistrationqualification'].ugInstitute.value;
	vyomAJAXProcessor(strURL,"result5");
}

function  vyomAJAXPGDetails()
{


	strURL = "/candidates/getPgdetails.asp?id=" + document.forms['frmUserRegistrationqualification'].pgInstitute.value;
	vyomAJAXProcessor(strURL,"result6");
}

function  vyomAJAXPostPGDetails()
{
	strURL = "/candidates/getPostPgdetails.asp?id=" + document.forms['frmUserRegistrationqualification'].masterInstitute.value;
	vyomAJAXProcessor(strURL,"result7");
}
function  vyomAJAXCandidateEdit()
{
	 
	updatepage("<IMG SRC='/images/loading1.gif'>","result8");
	strURL = "/getCountriesEdit.asp?id=" + document.forms['frmeditContactInfo'].cmbCountry1.value;
	vyomAJAXProcessor(strURL,"result8");
}
function  vyomAJAXEditEducation()
{
	updatepage("<IMG SRC='/images/loading1.gif'>","result9");
	strURL = "/getEditEducation.asp?id=" + document.forms['frmeditEducationalInfo'].ugInstitute.value;
	vyomAJAXProcessor(strURL,"result9");
}
function  vyomAJAXEditEducation1()
{
	updatepage("<IMG SRC='/images/loading1.gif'>","result10");
	strURL = "/getEditEducation1.asp?id=" + document.forms['frmeditEducationalInfo'].pgInstitute.value;
	vyomAJAXProcessor(strURL,"result10");
}
function  vyomAJAXEditEducation2()
{
	updatepage("<IMG SRC='/images/loading1.gif'>","result11");
	strURL = "/getEditEducation2.asp?id=" + document.forms['frmeditEducationalInfo'].masterInstitute.value;
	vyomAJAXProcessor(strURL,"result11");
}
function vyomCity()
{
	//alert(document.forms['frmUserRegistration'].subCategory.value);
	updatepage("<IMG SRC='/images/loading1.gif'>","result12");
	strURL = "/candidates/getcity.asp?id=" + document.forms['frmUserRegistration'].subCategory.value;
	vyomAJAXProcessor(strURL,"result12");
}

function  editvyomCity()
{
	updatepage("<IMG SRC='/images/loading.gif'>","result18");
	strURL = "/editgetcity.asp?id=" + document.forms['frmeditContactInfo'].subCategories.value;
	vyomAJAXProcessor(strURL,"result18");
}

function  vyomAJAXAlert()
{
	updatepage("<IMG SRC='/images/loading1.gif'>","result14");
	strURL = "/candidates/getAlertCountries.asp?id=" + document.forms['form'].alertCountry.value;
	vyomAJAXProcessor(strURL,"result14");
}

function  vyomAJAXAlertss()
{
	updatepage("<IMG SRC='/images/loading1.gif'>","result14");
	strURL = "/candidates/getAlertCountriesss.asp?id=" + document.forms['form'].alertCountry.value;
	vyomAJAXProcessor(strURL,"result14");
}

function  vyomAJAXRss()
{
	updatepage("<IMG SRC='/images/loading1.gif'>","resultcity");
	strURL = "/getRssCountries.asp?id=" + document.forms['frmRssview'].CountryName.value;
	vyomAJAXProcessor(strURL,"resultcity");
}

function  vyomRssCity()
{   
	updatepage("<IMG SRC='/images/loading1.gif'>","resultcity1");
	strURL = "/getrsscity.asp?id=" + document.forms['frmRssview'].currentCity.value;
	vyomAJAXProcessor(strURL,"resultcity1");
}

function  editvyomAJAXRegister(pId)
{	 
	profileId = pId
	updatepage("<IMG SRC='/images/loading1.gif'>","editResult");
	strURL = "/candidates/editGetCountry.asp?pId="+ profileId +"&id=" + document.forms['editProfile'].country.value;
	vyomAJAXProcessor(strURL,"editResult");
}

function  editvyomCities(pId)
{
	profileId = pId
	//alert(document.forms['editProfile'].editSubCategory.value)
	updatepage("<IMG SRC='/images/loading1.gif'>","Result20");
	strURL = "/candidates/editGetcities.asp?pId="+ profileId +"&id=" + document.forms['editProfile'].editSubCategory.value;
	vyomAJAXProcessor(strURL,"Result20");
}

function editvyomAJAXPreProcessorForugSpecilisationProfile(pId)
{    
	profileId = pId
	//alert(document.forms['editProfile'].ugQualification.value)
	//strURL = "/candidates/course.asp
	strURL = "/candidates/course.asp?pId="+profileId+"&id="+ document.forms['editProfile'].ugQualification.value;
	vyomAJAXProcessor(strURL,"hello");
	

	//divName = "result21";		
	//updatepage("<font face=verdana size=1 color=black>Please wait; loading ....</font>",divName);
	//strURL = "/candidates/editugSpecilisation-ajax.asp?name=" + document.forms['editProfile'].ugQualification.value;
	//vyomAJAXProcessor(strURL,"result21");
}
function editvyomAJAXPreProcessorForpgSpecilisationProfile(value)
{    
	
	if(value==0) 
	{
		divName = "result22";
	}
	else
	{
		divName = "result22" + value;
    }
	
	updatepage("<font face=verdana size=1 color=black>Please wait; loading ....</font>",divName);
	strURL = "/candidates/editpgSpecilisation-ajax.asp?name2=" + document.forms['editProfile'].pgQualification.value;
	vyomAJAXProcessor(strURL,"result22");
}

function editvyomAJAXPreProcessorForpostpgSpecilisationProfile(value)
{    
	divName = "result33";	
	updatepage("<font face=verdana size=1 color=black>Please wait; loading ....</font>",divName);
	strURL = "/candidates/editpostpgSpecilisation-ajax.asp?name3=" + document.forms['editProfile'].masterQualification.value;
	vyomAJAXProcessor(strURL,"result33");
}

function  vyomeditAJAXAlert()
{	 
	updatepage("<IMG SRC='/images/loading1.gif'>","result24");
	strURL = "/candidates/getEditCountryAlert.asp?id=" + document.forms['myform'].country.value;
	vyomAJAXProcessor(strURL,"result24");
}

function  vyomAJAXsocialNetworking()
{	 
	updatepage("<IMG SRC='/images/loading1.gif'>","result41");
	strURL = "/candidates/getCountrysocialNetworking.asp?id=" + document.forms['frmsocialNetworking'].cmbCountry.value;
	vyomAJAXProcessor(strURL,"result41");
}

function vyomAJAXProfileCreation()
{	 
	updatepage("<IMG SRC='/images/loading1.gif'>","result41");
	strURL = "/candidates/getCountries.asp?id=" + document.forms['profile'].cmbCountry.value;
	vyomAJAXProcessor(strURL,"result41");
}

function  vyomAJAXeditCommunity()
{	 
	updatepage("<IMG SRC='/images/loading1.gif'>","result44");
	strURL = "/candidates/getCountryEditCommunity.asp?id=" + document.forms['frmeditCommunity'].cmbCountry.value;
	vyomAJAXProcessor(strURL,"result44");
}

function vyomAJAXProfile()
{	 
	updatepage("<IMG SRC='/images/loading1.gif'>","result50");
	strURL = "/candidates/getCountryProfile.asp?id=" + document.forms['frmProfile'].cmbCountry.value;
	vyomAJAXProcessor(strURL,"result50");
}

function enableFunctionalArea()
{	
	
	updatepage("<IMG SRC='/images/loading1.gif'>","area");
	strURL = "/ad-min/newsletters/getFuncArea.asp?id=" + document.forms['frm'].memberType.value;
	vyomAJAXProcessor(strURL,"area");
}

function vyomAJAXProfileForugSpecilisation(value)
{    	
	if(value==0) 
	{
		divName = "result51";
	}
	else
	{
		divName = "result51" + value;
    }
	
	updatepage("<font face=verdana size=1 color=black>Please wait; loading ....</font>",divName);
	strURL = "/candidates/ugProfileSpecilisation-ajax.asp?name=" + document.forms['frmUserProfilequalification'].ugQualification.value;
	vyomAJAXProcessor(strURL,"result51");
}

function vyomAJAXProfileForpgSpecilisation(value)
{    	
	if(value==0) 
	{
		divName = "result52";
	}
	else
	{
		divName = "result52" + value;
    }
	
	updatepage("<font face=verdana size=1 color=black>Please wait; loading ....</font>",divName);
	strURL = "/candidates/pgProfileSpecilisation-ajax.asp?name=" + document.forms['frmUserProfilequalification'].pgQualification.value;
	vyomAJAXProcessor(strURL,"result52");
}

function vyomAJAXProfileForpostpgSpecilisation(value)
{    	
	if(value==0) 
	{
		divName = "result53";
	}
	else
	{
		divName = "result53" + value;
    }
	
	updatepage("<font face=verdana size=1 color=black>Please wait; loading ....</font>",divName);
	strURL = "/candidates/postpgProfileSpecilisation-ajax.asp?name=" + document.forms['frmUserProfilequalification'].masterQualification.value;
	vyomAJAXProcessor(strURL,"result53");
}

function vyomAJAXCompanies()
{
	updatepage("<font class='textbox'>Retrieving...</font>","result");
	strURL = "/ad-min/packages.asp?id=" + document.forms['myform'].newsCategory.value;
	vyomAJAXProcessor(strURL,"result");
}

function vyomAJAXJobQualification()
{
	updatepage("<font class='helptext'>Retrieving Branches...</font>","result");
	strURL = "getJobStream.asp?id=" + document.forms['form'].jobQualification.value;
	vyomAJAXProcessor(strURL,"result");
}

function vyomAJAXJobStreamEdit()
{
	updatepage("<font class='helptext'>Retrieving Branches...</font>","result");
	strURL = "getJobStreamEdit.asp?id=" + document.forms['form'].jobQualification.value + "&jobId=" + document.forms['form'].jobId.value;
	vyomAJAXProcessor(strURL,"result");
}

function vyomAJAXJobSource()
{
	updatepage("<font class='helptext'>Retrieving Sources...</font>","result1");
	strURL = "getJobSource.asp?id=" + document.forms['frmJob'].jobSourceName.value;
	vyomAJAXProcessor(strURL,"result1");
}

function vyomAJAXJobSourceEdit()
{
	updatepage("<font class='helptext'>Retrieving Sources...</font>","result1");
	strURL = "/ad-min/jobs/getJobSourceEdit.asp?id=" + document.forms['form'].jobSourceId.value + "&jobId=" + document.forms['form'].jobId.value;;
	vyomAJAXProcessor(strURL,"result1");
}

function vyomAJAXJobsOnDemand()
{
	updatepage("<font class='helptext'>Retrieving Roles...</font>","jobRoleId");
	strURL = "/candidates/getJobRoles.asp?id=" + document.forms['frm'].Function.value;
	vyomAJAXProcessor(strURL,"jobRoleId");
}

function vyomAJAXEditJobRole()
{
	updatepage("<font class='helptext'>Retrieving Roles...</font>","jobRolediv");
	strURL = "/ad-min/jobs/getJobRoles.asp?id=" + document.forms['frmJob'].Function.value;
	vyomAJAXProcessor(strURL,"jobRolediv");
}

function vyomAJAXBranches()
{
	updatepage("<font class='helptext'>Retrieving Branches...</font>","branchId");
	strURL = "/ad-min/jobs/getbranches.asp?id=" + document.forms['form'].course.value;
	vyomAJAXProcessor(strURL,"branchId");
}
function vyomAJAXJobRoles()
{
	
	updatepage("<font class='helptext'>Retrieving Roles...</font>","jobRoleId");
	strURL = "getJobRoles.asp?id=" + document.forms['form'].Function.value;
	vyomAJAXProcessor(strURL,"jobRoleId");
}
function vyomAJAXJobsKeyskills()
{
   updatepage("<font class='helptext'>Retrieving Roles...</font>","Jobkeyskilldiv");
	strURL = "/ad-min/jobs/getJobkeyskill.asp?id=" + document.forms['frmJob'].Function.value;
	vyomAJAXProcessor(strURL,"Jobkeyskilldiv");
	return true();
}
function vyomAJAXJobsJobRole()
{
   
	updatepage("<font class='helptext'>Retrieving Roles...</font>","jobRoledivName");
	strURL = "/ad-min/jobs/getJobRoles.asp?id=" + document.forms['frmJob'].Function.value;
	vyomAJAXProcessor(strURL,"jobRoledivName");
	return true();
}
function vyomAJAXJobRole()
{
	
	updatepage("<font face=verdana size=2>Retrieving Roles...</font>","jobRolediv");
	strURL = "/employers/jobs/getJobRoles.asp?id=" + document.forms['frmJob'].Function.value;
	vyomAJAXProcessor(strURL,"jobRolediv");
	return true();
}

function vyomAJAXPlacementPaperRole()
{
	updatepage("<font face=verdana size=2>Retrieving Roles...</font>","jobRolediv");
	strURL = "/ad-min/placement-papers/getJobRoles.asp?id=" + document.forms['frmPaper'].FunctionalArea.value;
	vyomAJAXProcessor(strURL,"jobRolediv");
	return true();
}

function vyomAJAXPlacementPaperDomains()
{
	updatepage("<font face=verdana size=2>Retrieving Roles...</font>","jobDomaindiv");
	strURL = "/ad-min/placement-papers/getJobDomain.asp?id=" + document.forms['frmPaper'].FunctionalArea.value;
	vyomAJAXProcessor(strURL,"jobDomaindiv");
	return true();
}

function vyomAJAXTrainingInstituteRole()
{
	
	updatepage("<font face=verdana size=2>Retrieving Roles...</font>","jobRolediv");
	strURL = "/ad-min/training-institutes/getJobRoles.asp?id=" + document.forms['training'].FunctionalArea.value;
	vyomAJAXProcessor(strURL,"jobRolediv");
	return true();
}
function vyomAJAXConsultantRole()
{ 
	
	updatepage("<font class='helptext'>Retrieving Roles...</font>","jobRolediv");
	strURL = "/ad-min/consultants/getJobRoles.asp?id=" + document.forms['frmConsultant'].FunctionalArea.value;
    vyomAJAXProcessor(strURL,"jobRolediv");
	return true();
}

function vyomAJAXTrainingInstituteDomains()
{
	updatepage("<font class='helptext'>Retrieving Domains...</font>","jobDomaindiv");
	strURL = "/ad-min/training-institutes/getJobDomain.asp?id=" + document.forms['training'].FunctionalArea.value;
	vyomAJAXProcessor(strURL,"jobDomaindiv");
	return true();
}
function vyomAJAXTrainingInstituteKeyskills()
{
	updatepage("<font class='helptext'>Retrieving Keyskills...</font>","keyskilldiv");
	strURL = "/ad-min/training-institutes/getKeyskill.asp?id=" + document.forms['training'].FunctionalArea.value;
	vyomAJAXProcessor(strURL,"keyskilldiv");
	return true();
}
function vyomAJAXConsultantDomains()
{
	updatepage("<font class='helptext'>Retrieving Domains...</font>","jobDomaindiv");
	strURL = "/ad-min/consultants/getJobDomain.asp?id=" + document.forms['consultant'].FunctionalArea.value;
	vyomAJAXProcessor(strURL,"jobDomaindiv");
	return true();
}

function vyomAJAXConsultantSkills()
{
	updatepage("<font class='helptext'>Retrieving Keyskills...</font>","keyskilldiv");
	strURL = "/ad-min/consultants/getKeyskills.asp?id=" + document.forms['frmConsultant'].FunctionalArea.value;
	vyomAJAXProcessor(strURL,"keyskilldiv");
	return true();
}
function vyomAJAXJobKeyskills()
{
	updatepage("<font face=verdana size=2>Retrieving Keyskills...</font>","DivKeyskill");
	strURL = "/employers/jobs/getKeyskill.asp?id=" + document.forms['frmJob'].Function.value;
	vyomAJAXProcessor(strURL,"DivKeyskill");
	return true();
}
function vyomAJAXJobDomains()
{
	updatepage("<font class='helptext'>Retrieving Domains...</font>","jobDomaindiv");
	strURL = "/employers/jobs/getJobDomain.asp?id=" + document.forms['form'].Function.value;
	vyomAJAXProcessor(strURL,"jobDomaindiv");
	return true();
}

function vyomAJAXKeyskills()
{
	updatepage("<font class='helptext'>Retrieving Domains...</font>","keySkilldiv");
	strURL = "/employers/jobs/getKeyskills.asp?id=" + document.forms['form'].Function.value;
	vyomAJAXProcessor(strURL,"keySkilldiv");
	return true();
}

function vyomAjaxGenerateJobRole()
{
	updatepage("<font class='helptext'>Retrieving Roles...</font>","jobRolediv");
	strURL = "/ad-min/newsletters/getJobRoles.asp?id=" + document.forms['frm'].functionalarea.value;
	vyomAJAXProcessor(strURL,"jobRolediv");
}

function vyomAjaxGenerateJobDomain()
{
	updatepage("<font class='helptext'>Retrieving Roles...</font>","jobDomaindiv");
	strURL = "/ad-min/newsletters/getJobDomains.asp?id=" + document.forms['frm'].functionalarea.value;
	vyomAJAXProcessor(strURL,"jobDomaindiv");	
}
	
function vyomAJAXJobDomain()
{
	updatepage("<font class='helptext'>Retrieving Roles...</font>","jobDomainDiv");
	strURL = "/employers/jobs/getJobDomains.asp?id=" + document.forms['form'].Function.value;
	vyomAJAXProcessor(strURL,"jobDomainDiv");
	return true();
}

function vyomAJAXJobRoleNew()
{	
	updatepage("<font class='helptext'>Retrieving Roles...</font>","jobRoleId");
	strURL = "getJobRoles.asp?id=" + document.forms['form'].Function.value;
	vyomAJAXProcessor(strURL,"jobRoleId");
}

function VYOMAJAXEditNews(a)
{
	strURL = "/ad-min/news/getNews.asp?id="+ document.forms['myform'].newsHead.value+"&a="+a;
	vyomAJAXProcessor(strURL,"fileName");
}

function vyomAJAXTab(value)
{
	var date = new Date();
	var secs = date.getMilliseconds;

	updatepage("<br><br> <table align=center><tr><td><font class=bigText> Loading </font></td></tr></table> <br> <center> <img src='/images/loading12.gif'></center><br><br>","result");
	strURL = "getJobs.asp?id=" + value + "&rnd=" + secs;
	vyomAJAXProcessor(strURL,"result");
}

function vyomAJAXTab2(value)
{
	var date = new Date();
	var secs = date.getMilliseconds;

	updatepage("<br><br> <table align=center><tr><td><font class=bigText> Loading </font></td></tr></table> <br> <center> <img src='/images/loading12.gif'></center><br><br>","result1");
	strURL = "getSite.asp?id=" + value + "&rnd=" + secs;
	vyomAJAXProcessor(strURL,"result1");
}

function vyomAJAXTab3(value)
{
	var date = new Date();
	var secs = date.getMilliseconds;

	updatepage("<br><br> <table align=center><tr><td><font class=bigText> Loading </font></td></tr></table> <br> <center> <img src='/images/loading12.gif'></center><br><br>","result2");
	strURL = "getSite1.asp?id=" + value + "&rnd=" + secs;
	vyomAJAXProcessor(strURL,"result2");
}

function vyomAJAXTab4(value)
{
	var date = new Date();
	var secs = date.getMilliseconds;

	updatepage("<br><br> <table align=center><tr><td><font class=bigText> Loading </font></td></tr></table> <br> <center> <img src='/images/loading12.gif'></center><br><br>","result3");
	strURL = "getJobs1.asp?id=" + value + "&rnd=" + secs;
	vyomAJAXProcessor(strURL,"result3");
}


function vyomAJAXCheckUser()
{    
	updatepage("<font color=#EDE941 size=2>Checking...</font>","result");
	strURL = "/candidates/checkUser.asp?email=" + document.forms['frmUserRegistration'].txtEmail.value;
	vyomAJAXProcessor(strURL,"result");
}
function vyomAJAXCheckCollegeUser()
{   
	updatepage("<font color=#EDE941 size=2>Checking...</font>","resultCollege");
	strURL = "/college-campus/checkCollegeUser.asp?email=" + document.forms['collegeregistration'].UserName.value;
	vyomAJAXProcessor(strURL,"resultCollege");
}
function  vyomAJAXEmployerRegister()
{	
	updatepage("<IMG SRC='/images/loading1.gif'>","result1");
	strURL = "/employers/getCountryRegistration.asp?id=" + document.forms['register'].Country.value;
	vyomAJAXProcessor(strURL,"result1");
}
function  vyomAJAXEmployerRegisterOtherCity()
{	
	//alert("hi")
	updatepage("<IMG SRC='/images/loading1.gif'>","otherCity");
	strURL = "/employers/getOtherCity.asp?id=" + document.forms['register'].subCategory.value;
	vyomAJAXProcessor(strURL,"otherCity");
}
function  vyomAJAXEmployerEdit()
{	
	updatepage("<IMG SRC='/images/loading1.gif'>","result");
	strURL = "/employers/getCountryEdit.asp?id=" + document.forms['frmEditEmp'].Country.value;
	vyomAJAXProcessor(strURL,"result");
}
function vyomAJAXTab(value)
{
	var date = new Date();
	var secs = date.getMilliseconds;

	updatepage("<br><br> <table align=center><tr><td><font class=bigText> Loading </font></td></tr></table> <br> <center> <img src='/images/loading12.gif'></center><br><br>","result");
	strURL = "getJobs.asp?id=" + value + "&rnd=" + secs;
	vyomAJAXProcessor(strURL,"result");
}

function vyomAJAXTab2(value)
{
	var date = new Date();
	var secs = date.getMilliseconds;

	updatepage("<br><br> <table align=center><tr><td><font class=bigText> Loading </font></td></tr></table> <br> <center> <img src='/images/loading12.gif'></center><br><br>","result1");
	strURL = "getSite.asp?id=" + value + "&rnd=" + secs;
	vyomAJAXProcessor(strURL,"result1");
}

function vyomAJAXTab3(value)
{
	var date = new Date();
	var secs = date.getMilliseconds;

	updatepage("<br><br> <table align=center><tr><td><font class=bigText> Loading </font></td></tr></table> <br> <center> <img src='/images/loading12.gif'></center><br><br>","result2");
	strURL = "getSite1.asp?id=" + value + "&rnd=" + secs;
	vyomAJAXProcessor(strURL,"result2");
}

function vyomAJAXTab4(value)
{
	var date = new Date();
	var secs = date.getMilliseconds;

	updatepage("<br><br> <table align=center><tr><td><font class=bigText> Loading </font></td></tr></table> <br> <center> <img src='/images/loading12.gif'></center><br><br>","result3");
	strURL = "getJobs1.asp?id=" + value + "&rnd=" + secs;
	vyomAJAXProcessor(strURL,"result3");
}


function vyomAJAXChecking()
{
	document.forms['frmUserRegistration'].txtEmail.value="";
}

function  vyomAJAXEmployerRegister()
{	 
	if(document.forms['register'].Country.value == -9)
	{
		alert("Please select valid country name.");	
		return false;
	}
	if(document.forms['register'].Country.value == 0)
	{
		
		document.subCategory.disabled = true;
	}
	updatepage("<IMG SRC='/images/loading1.gif'>","result");
	strURL = "/employers/getCountryRegistration.asp?id=" + document.forms['register'].Country.value;
	vyomAJAXProcessor(strURL,"result");
}

function vyomAJAXCheckComapny()
{   
	
	updatepage("<font class='specialtext'></font>","result");
	strURL = "/ad-min/companies/checkcompany.asp?email=" + document.forms['form'].txtcompanyName.value;
	
	vyomAJAXProcessor(strURL,"result");	
}

function AjaxChangeCityImage(cityId,id)
{
	updatepage("<img src='/images/loading.gif'>","city"+id);
	siteURL = "/ad-min/jobs/upload-city-image.asp?cid="+cityId+"&id="+id;
	vyomAJAXProcessor(siteURL,"city"+id);
}

function AjaxSelectedCriteria()
{
	updatepage("<img src='/images/loading.gif'>","divscriteria");
	siteURL = "/ad-min/newsletters/get-selected-criteria.asp?sc="+document.forms['bnewsletter'].criteria.value;
	vyomAJAXProcessor(siteURL,"divscriteria");
}

function ajaxUploadCompImage(id)
{
	updatepage("<img src='/images/loading.gif'>","compimage"+id);
	siteURL = "/ad-min/companies/upload-company-image.asp?id="+id;
	vyomAJAXProcessor(siteURL,"compimage"+id);	
}

function ajaxUploadComplogo()
{
	updatepage("<img src='/images/loading.gif'>","complogo");
	siteURL = "/ad-min/companies/upload-company-logo.asp";
	vyomAJAXProcessor(siteURL,"complogo");
}

function ajaxDesiredBox(candidateId)
{
	updatepage("<img src='/images/loading.gif'>","desiredbox");
	siteURL = "/ad-min/manage-candidates/get-desired-box.asp?id="+ document.forms['frmEditProfile'].editcombo.value +"&cid="+ candidateId;
	vyomAJAXProcessor(siteURL,"desiredbox");
}

function ajaxAlertSkills()
{
	updatepage("<img src='/images/loading.gif'>","alertSkill");
	siteURL = "/candidates/job-alerts/getKeyskill.asp?id="+ document.forms['frmAlert'].functionalArea.value;
	vyomAJAXProcessor(siteURL,"alertSkill")
}

function ajaxCheckCompany()
{
	siteURL = "/employers/check-company.asp?cid="+document.forms['register'].compId.value;
	vyomAJAXProcessor(siteURL,"chkcomp");
}

function ajaxCheckCollege()
{
	siteURL = "/college-campus/check-college.asp?cid="+document.forms['collegeregistration'].collegeId.value;
	vyomAJAXProcessor(siteURL,"chkcollege");
}

function ajaxCheckEmployerCompany()
{
	siteURL = "/ad-min/employers/check-company.asp?cid="+document.forms['frmEditEmp'].compId.value;
	vyomAJAXProcessor(siteURL,"chkcomp");
}

function ajaxCheckEmail()
{
	siteURL = "/employers/check-email.asp?eid="+document.forms['register'].uEmailId.value;
	vyomAJAXProcessor(siteURL,"chkemail");
}

function ajaxCheckTemplate()
{
	updatepage("<IMG SRC='/images/loading1.gif'>...","chkTemp");
	siteURL = "/employers/get-template.asp?tid="+document.forms['frmShortList'].template.value;
	vyomAJAXProcessor(siteURL,"chkTemp");
}

function selectCity()
{
siteURL ="/candidates/get-city.asp?id="+document.forms['resume'].country.value
vyomAJAXProcessor(siteURL,"chkTemp1");
}

function ajaxCheckBranch()
{
	
siteURL ="/college-campus/get-branch.asp?courseid="+document.forms['selectcourse'].Course.value
vyomAJAXProcessor(siteURL,"chkCourse");
}

function ajaxCheckFunctionalArea()
{
	
siteURL ="/candidates/get-functionalarea.asp?functionalid="+document.forms['frmUserRegistration'].txtFunctionalArea.value
vyomAJAXProcessor(siteURL,"chkFunctional");
}4

function ajaxCheckIndustryType()
{
	
siteURL ="/candidates/get-industrytype.asp?industrialid="+document.forms['frmUserRegistration'].txtCurrentIndustry.value
vyomAJAXProcessor(siteURL,"chkIndustry");
}
function ajaxcheckInstitute(pId)
{
	profileId = pId
	updatepage("<font class='helptext'>Your institute...</font>","check");
	strURL = "/candidates/check-Institute.asp?pId="+profileId+"&id=" + document.forms['editProfile'].ugInstitutes.value;
	vyomAJAXProcessor(strURL,"check");
}


function other()
{    
	//alert("Hi")
  // alert("id="+ document.forms['editProfile'].ugQualification.value)
	updatepage("<font class='helptext'>other course...</font>","hello");
	strURL = "/employers/course.asp?id="+ document.forms['editProfile'].ugQualification.value;
	vyomAJAXProcessor(strURL,"hello");
	//alert("final")
}
function ajaxCheckInstitute()
{
siteURL ="/candidates/get-institute.asp?instituteid="+document.forms['frmUserRegistrationqualification'].ugInstitute.value
vyomAJAXProcessor(siteURL,"chkInstitute");
}
function ajaxpass()
{
	
	//alert("india")
	strURL = "/candidates/s.asp?strength="+document.forms['frm'].pass.value;
	vyomAJAXProcessor(strURL,"strength");
}
function ajaxCheckOrganisation()
{
	
siteURL ="/candidates/get-organisation.asp?organisationid="+document.forms['frmUserRegistrationqualification'].typeOrganisation.value
vyomAJAXProcessor(siteURL,"chkOrganisation");
}

function ajaxCheckPostPgFunctional()
{
	
siteURL ="/candidates/get-functionalarea.asp?functionalid="+document.forms['frmUserRegistrationqualification'].functionalArea.value
vyomAJAXProcessor(siteURL,"chkPostPgFunctional");
}

function ajaxCheckUgSelect()
{
	
siteURL ="/candidates/get-ugselect.asp?ugselectid="+document.forms['frmUserRegistrationqualification'].qualificationId.value
vyomAJAXProcessor(siteURL,"ugselect");
}


function ajaxCheckPgSelect()
{
	
siteURL ="/candidates/get-pgselect.asp?pgselectid="+document.forms['frmUserRegistrationqualification'].qualificationId1.value
vyomAJAXProcessor(siteURL,"pgselect");
}


function ajaxCheckPostPgSelect()
{
	
siteURL ="/candidates/get-postpgselect.asp?postpgselectid="+document.forms['frmUserRegistrationqualification'].qualificationId2.value
vyomAJAXProcessor(siteURL,"postpgselect");
}

function vyomAJAXMaxExperience()
{	
	
siteURL ="/employers/get-maximum-experience.asp?id="+document.forms['form'].minExp.value;
vyomAJAXProcessor(siteURL,"expRes");
}
function vyomAJAXPostJobMaxExperience()
{	
	siteURL ="/employers/get-maximum-experience.asp?id="+document.forms['frmJob'].minExperience.value;
	vyomAJAXProcessor(siteURL,"expRes");
}
function vyomAJAXPostJobMaxExperienceAdmin()
{	
	siteURL ="/ad-min/jobs/get-maximum-experience.asp?id="+document.forms['frmJob'].minExperience.value;
	vyomAJAXProcessor(siteURL,"expRes");
}
function vyomAJAXPostJobEditMaxExperience(jobId)
{
	siteURL ="/employers/get-maximum-experience.asp?id="+document.forms['frmJob'].minExperience.value+"&jobId="+jobId;
	vyomAJAXProcessor(siteURL,"expRes");
}

function vyomAJAXMaxSalary()
{	
siteURL ="/employers/get-maximum-salary.asp?id="+document.forms['form'].annualSalaryMin.value;
vyomAJAXProcessor(siteURL,"salRes");
}

function ajaxCheckCompanyName()
{
	siteURL = "/employers/check-company-name.asp?cid="+document.forms['register'].companyName.value;
	vyomAJAXProcessor(siteURL,"chkcomp");
}
function vyomAjaxOtherCity()
{
	//alert(document.forms['frmcomp'].OOA1Country.value);
	siteURL = "/ad-min/companies/get-other-city.asp?id="+document.forms['frmcomp'].city.value;
	vyomAJAXProcessor(siteURL,"otherCity");
}
function selectState()
{
	//alert(document.getElementById("country").value);
   updatepage("<IMG SRC='/images/loading1.gif'> \n Loading...","state");
   strURL = "/ad-min/companies/get-states.asp?id="+ document.getElementById("country").value;
	vyomAJAXProcessor(strURL,"state")

}

function selectCompanyCity()
{
	//alert("hi");
	//alert(document.forms['frmcomp'].state.value);
	strURL = "/ad-min/companies/get-city.asp?id="+ document.forms['frmcomp'].state.value;
	vyomAJAXProcessor(strURL,"cit")
}
	function otherCity()
{
	//alert(document.forms['postad'].state.value)
	strURL = "/ad-min/companies/other-city.asp?id="+ document.forms['frmcomp'].city.value;
	vyomAJAXProcessor(strURL,"othercit")
}

	function selectNotification()
{
	id = document.forms['frmExamination'].notificationFor.value;
	updatepage("<IMG SRC='/images/loading1.gif'>","notification");
	strURL = "/ad-min/notifications/getNotification.asp?id="+id;
	vyomAJAXProcessor(strURL,"notification");
}

function vyomAjaxGetExam()
{
	id = document.forms['frmExamination'].examType.value;
	updatepage("<IMG SRC='/images/loading1.gif'>","exam");
	strURL = "/ad-min/notifications/getExamination.asp?id="+id;
	vyomAJAXProcessor(strURL,"exam");
}
function vyomAJAXComments()
{
	id = document.getElementById("comment").value;
	strURL = "/companies/profiles/comment.asp?id="+id;
	vyomAJAXProcessor(strURL,"commentDiv");
}