
function writeTime(){
d = new Array(
"Sunday",
"Monday",
"Tuesday",
"Wednesday",
"Thursday",
"Friday",
"Saturday"
);
m = new Array(
"January",
"February",
"March",
"April",
"May",
"June",
"July",
"August",
"September",
"October",
"November",
"December"
);

today = new Date();
day = today.getDate();
year = today.getYear();

if (year < 2000)    
year = year + 1900; 

end = "th";
if (day==1 || day==21 || day==31) end="st";
if (day==2 || day==22) end="nd";
if (day==3 || day==23) end="rd";
day+=end;

document.write(" ");
document.write(d[today.getDay()]+" "+m[today.getMonth()]+" ");
document.write(day+" " + year);
document.write(" ");
}
function openLinks2(theURL,winName) { //v2.0 
    window.open(theURL,winName,'height=425,width=250,toolbar=0,resizable=0,menubar=0,scrollbars=0');
}
function openLinks(theURL,winName) { //v2.0 
    window.open(theURL,winName,'height=425,width=250,toolbar=0,resizable=0,menubar=0,scrollbars=0');
}
function printerFriendly(theURL,winName) { //v2.0 
    window.open(theURL,winName,'height=475,width=465,toolbar=0,resizable=1,menubar=0,scrollbars=1');
}
function openWindow(theURL,winName) { //v2.0 
    window.open(theURL,winName,'height=540,width=762,toolbar=0,top=38,left=50,menubar=0');

}
function check_form() {
	if (document.login.txtUsername.value.length == 0)
		{
		 alert("Please enter a username to continue");
		 document.login.txtUsername.focus();	
		 return false;
		}
								
		if (document.login.txtPassword.value.length == 0)
		{
		alert("Please enter a password to continue");
		document.login.txtPassword.focus();
		return false;
		}											
		return true;				
		}				
		
function checkAskForm() {
myEmail=document._main.p_userid.value;
myQuestion=document._main.p_question.value;

if(myEmail=="") {
  alert("Please enter your E-mail Address");
  document._main.p_userid.focus();
} else if(myEmail!=""){

	var searchChar = "None";
	var searchChar2 = "None";
	
	searchChar = myEmail.indexOf("@");
	searchChar2 = myEmail.indexOf(".");

	if (searchChar == -1 && searchChar2 == -1 || searchChar == -1 || searchChar2 == -1) {
		document._main.p_userid.focus();
		alert("Please enter a valid E-mail Address \x28e.g. name@company.com\x29");
		emailValid="no";
		} else {emailValid="yes";}
}

if(myQuestion==""&&emailValid=="yes"){
  alert("Please enter your Question");
  document._main.p_question.focus();
}
		
}

function openURL(theURL,winName) { //v2.0 
    window.open(theURL,winName,'height=300,width=544,toolbar=0,resizable=0,menubar=0');
}
function openBlog(theURL,winName) { //v2.0 
    window.open(theURL,winName,'height=500,width=525,toolbar=0,resizable=0,menubar=0');
}
function openArticlePopup(theURL,winName) { //v2.0 
    window.open(theURL,winName,'height=500,width=493,toolbar=0,resizable=0,menubar=0,scrollbars=1');
}
userCPU = navigator.cpuClass;
browserInfo = navigator.userAgent;
findVersion = browserInfo.indexOf("Windows");
findVersionStart = findVersion + 8;
findVersionEnd = findVersionStart + 3;
getOS = browserInfo.substr(findVersionStart, findVersionEnd);
getOS = getOS.substr(0,6);


