function validEmail(email) 
{ 
    if (email == ""){return false;} 
    badStuff = ";:/,' \"\\"; 
     
    for (i=0; i<badStuff.length; i++) 
    { 
        badCheck = badStuff.charAt(i) 
        if (email.indexOf(badCheck,0) != -1){return false;} 
    } 

    posOfAtSign = email.indexOf("@",1) 
     
    if (posOfAtSign == -1){return false;} 

    if (email.indexOf("@",posOfAtSign+1) != -1){return false;} 
    posOfPeriod = email.indexOf(".", posOfAtSign) 
     
    if (posOfPeriod == -1){return false;} 
    if (posOfPeriod+2 > email.length){return false;} 
     
return true; 
} 




function left_chk()
{

		var errorstr = '';
		var msgstr = "Sorry, we cannot complete your request.\nKindly provide us the missing or incorrect information enclosed below.\n\n";
		
		with(document.formleft)
		{ 	
			if(username.value=='') { errorstr += "- Please enter username.\n"; }
			if (password.value=='') { errorstr += "- Please enter password.\n";}
		}	
		
		if (errorstr != '')
		{
			msgstr = msgstr + errorstr;
			alert(msgstr);
			return false;
		}
		else
		{
			return true;
		}	
			
} 
