function ChangeColor(divName,lnkName,pos)
{
	//divName - button
	//lnkName - button text
	//evnName - Event Name Over or Out
	//pos - position of button L or R
	
	var controlName = 'UCJsPanel1_';
	var divPrevious = document.getElementById('divPrevious').value;
	var lnkPrevious = document.getElementById('lnkPrevious').value;
	var posPrevious = document.getElementById('posPrevious').value;
	
	if(!document.getElementById || !document.createTextNode) {return;}
	
	document.getElementById(controlName + lnkName).className = "normaltext";
	
	if(pos == 'L')
	{
		document.getElementById(divName).className = "leftactivebutton";
	}
	else
	{
		document.getElementById(divName).className = "rightactivebutton";
	}
	ShowInf(lnkName);

	if(divPrevious != divName)
	{
		document.getElementById(controlName + lnkPrevious).className = "whitetext";
		if(posPrevious == 'L')
		{
			document.getElementById(divPrevious).className = "leftinactivebutton";
		}
		else
		{
			document.getElementById(divPrevious).className = "rightinactivebutton";
		}
	}
	//Set current button div link and position to hidden textbox
	document.getElementById('divPrevious').value = divName;
	document.getElementById('lnkPrevious').value = lnkName;
	document.getElementById('posPrevious').value = pos;
}
/*
function ChangeColor(divName,lnkName,evnName,pos)
{
	// divName - button
	// lnkName - button text
	// evnName - Event Name Over or Out
	// pos - position of button L or R
	var contrlName = 'UCJsPanel1_';
	
	if(!document.getElementById || !document.createTextNode) {return;}
	
	if (evnName == 'Over')
	{
		document.getElementById(contrlName + lnkName).className = "normaltext";
		if(pos == 'L')
		{
			document.getElementById(divName).className = "leftactivebutton";
		}
		else
		{
			document.getElementById(divName).className = "rightactivebutton";
		}
		ShowInf(lnkName);
	}
	else
	{
		document.getElementById(contrlName + lnkName).className = "whitetext";
		if(pos == 'L')
		{
			document.getElementById(divName).className = "leftinactivebutton";
		}
		else
		{
			document.getElementById(divName).className = "rightinactivebutton";
		}
		//ClearInf();
	}
}
*/
function ShowInf(lnkName)
{
	switch(lnkName)
	{
		case "lnkMain":
			document.getElementById('divInf').innerHTML = '<span class="boldtext"><ul><li>Welcome to Jobsnet.asia: your job search portal</li>'
														+ '<li>Mouse over tab to read descriptions</li><li>Click on tab to access</li></ul></span>';
		break;
	
		case "lnkMyAccount":
			document.getElementById('divInf').innerHTML = '<span class="boldtext"><UL><LI>Change Password </LI><LI>Manage Job Alert </LI><LI>Set Resume Privacy </LI></UL></span>';
		break;
		
		case "lnkResume":
			document.getElementById('divInf').innerHTML = '<span class="boldtext"><UL><LI>Express Resume</LI><LI>Standard Resume</LI><LI>Web Resume</LI><LI>Upload Resume</LI></UL></span>';
		break;
		
		case "lnkRequest":
			document.getElementById('divInf').innerHTML = '<span class="boldtext"><UL><LI>Resume requests by employers</LI></UL></span>';	
		break;
		
		case "lnkWebResume":
			document.getElementById('divInf').innerHTML = '<span class="boldtext"><UL><LI>Your very own http (web form) resume</LI>'
														+ '<li>You may use this resume to apply for jobs out of jobf1.com website</li>'	
														+ '<li>Remember to set a password to protect it if you don\'t wish to open it to the public</li></UL></span>';
		break;
		
		case "lnkCoverLetter":
			document.getElementById('divInf').innerHTML = '<span class="boldtext"><UL><LI>Save up to 2 covering letter for your job applications</LI></UL></span>';
		break;
		
		case "lnkHistory":
			document.getElementById('divInf').innerHTML = '<span class="boldtext"><UL><li>Jobs you have applied before</li></UL></span>';
		break;
		
		case "lnkPrivateMail": 
			document.getElementById('divInf').innerHTML = '<span class="boldtext"><UL><LI>Your private mail for job applications</LI></UL></span>';
		break;
		
		case "lnkJobSearch":
			document.getElementById('divInf').innerHTML = '<span class="boldtext"><UL><LI>Various options of searching jobs</LI></UL></span>';
		break;
		
		case "lnkAdvanceSearch":
			document.getElementById('divInf').innerHTML = '<span class="boldtext"><UL><LI>Advance job search with multiple fields for more specific job search</LI></UL></span>';
		break;
		case "lnkMatchJob":
			document.getElementById('divInf').innerHTML = '<span class="boldtext"><UL><LI>Click to see the matched jobs for you</LI></UL></span>';
		break;	
		
		case "lnkJobAlert":
			document.getElementById('divInf').innerHTML = '<span class="boldtext"><UL><LI>Manage your job alert here</LI></UL></span>';
		break;
		
		case "lnkBrowseJob":
			document.getElementById('divInf').innerHTML = '<span class="boldtext"><UL><LI>Browse all latest jobs here</LI></UL></span>';
		break;
		
		case "lnkResumePrivacy":
			document.getElementById('divInf').innerHTML = '<span class="boldtext"><UL><LI>Set your resume privacy here</LI>'
														+ '<Li>Open to employer for searches or close it completely for inactive job seekers</LI></UL></span>';
		break;
		
		case "lnkResource": 
			document.getElementById('divInf').innerHTML = '<span class="boldtext"><UL><LI>View the resource for job seekers, resume and cover letter writing</LI>' 
														+ '<LI>Resources for job seekers, employment and career</LI></UL></span>';
		break;	
		
		case "lnkAbout": 
			document.getElementById('divInf').innerHTML = '<span class="boldtext"><UL><LI>Job Seekers FAQ</li><li>Contact us at admin@Jobsnet.asia</LI></UL></span>';
		break;
		
	}
}

function ClearInf()
{
	document.getElementById('divInf').innerHTML = '';
}

/*===============================
This function click link button when click on div in UCJsPanel
===============================*/
function ClickLink(lnkName)
{
	if(!document.getElementById || !document.createTextNode) {return;}
	var controlName = 'UCJsPanel1_';
	document.getElementById(controlName + lnkName).click();
}

/*===============================
These function are copied from JSDefault link click
===============================*/

function ViewJobAd(RecId,JobId)
{
	var URLAddress = "ViewJobAd.aspx?RID=" + RecId + "&JID=" + JobId;
	openWindow(URLAddress,'WinPopUp','24','24','700','600','no','yes','');
	return;
}
function ViewCompanyProfile(RecId)
{
	var URLAddress = "ViewCompanyProfile.aspx?RID=" + RecId ;
	openWindow(URLAddress,'WinPopUp','24','24','700','600','no','yes','');
	return;
}
function ViewWebProfile(RecId)
{
	var URLAddress = "../ViewWebProfile.aspx?RID=" + RecId ;
	openWindow(URLAddress,'WinPopUp','24','24','700','600','no','yes','');
	return;
}