<!-- //
textDelay = 80;

txt = new Object();

var cnt=0;
var strMesg="                             ";
var counter=-1;
startHelp=0;
strCounter = 0;
strTimeout = 0;
var strObj
errorColor = "#F5A41B";
textColor = "#AAAAAA";

function helpText(strObj,strMesg)
{
if(startHelp)
{
strLen=strMesg.length;
curObj=strObj;
clearTimeout(cnt);
strObj.value+=strMesg.charAt(counter);
counter++;
if (counter>=strLen)
{
return; startHelp=0;
counter=0;
cnt=0;
}
cnt=setInterval("helpText(eval(curObj),strMesg)",textDelay);
};
strCounter++;
}

strOldValue = "";
function clearText(strObj)
{
startHelp=0;
if(!document.layers) strObj.style.color = textColor;
strObj.value=strOldValue;
strObj.focus();

thisForm.sendbutton.disabled = false;
}

function checkRequest()
{
thisForm=document.forms['FForm'];

txt.NameObj = thisForm.name;
txt.EmailObj = thisForm.email;
txt.PhoneObj = thisForm.phone;


// Name : Begin
if (txt.NameObj.value.length < 3)
{
if(!document.layers) txt.NameObj.style.color = errorColor;
txt.NameObj.focus();
strOldValue = txt.NameObj.value;
strMesg="Enter your name...";
txt.NameObj.value="";
startHelp=1;
helpText(txt.NameObj, strMesg)
cnt=counter=strCounter=0;
setTimeout("clearText(txt.NameObj)",2000);
return (false);
}
// Name : End

// Email : Begin
if (txt.EmailObj.value.length < 5)
{
if(!document.layers) txt.EmailObj.style.color = errorColor;
txt.EmailObj.focus();
strOldValue = txt.EmailObj.value;
strMesg="Enter e-mail address...";
txt.EmailObj.value="";
startHelp=1;
helpText(txt.EmailObj,strMesg);
cnt=counter=strCounter=0;
setTimeout("clearText(txt.EmailObj)",2500);
return (false);
}

em=0;
em=txt.EmailObj.value.indexOf("@");
if (em==-1)
{
if(!document.layers) txt.EmailObj.style.color = errorColor;
txt.EmailObj.focus();
strOldValue = txt.EmailObj.value;
strMesg="E-mail address incorrect...";
txt.EmailObj.value="";
startHelp=1;
helpText(txt.EmailObj,strMesg);
cnt=counter=strCounter=0;
setTimeout("clearText(txt.EmailObj)",2500);
return (false);
}

emp=0;
emp=txt.EmailObj.value.indexOf(".");

if (emp==-1)
{
if(!document.layers) txt.EmailObj.style.color = errorColor;
txt.EmailObj.focus();
strOldValue = txt.EmailObj.value;
strMesg="E-mail address incorrect...";
txt.EmailObj.value="";
startHelp=1;
helpText(txt.EmailObj,strMesg);
cnt=counter=strCounter=0;
setTimeout("clearText(txt.EmailObj)",2500);
return (false);
}
// Email : End

return(true);
}

function FormFocus()
{
thisForm=document.forms['FForm'];

txt.NameObj = thisForm.NameObj;
txt.NameObj.focus();
}

function ResetForm()
{
thisForm=document.forms['FForm'];

txt.NameObj = thisForm.Name;
txt.EmailObj = thisForm.Email;
txt.PhoneObj = thisForm.Phone;


with (txt)
{
NameObj.value="";
EmailObj.value="";
PhoneObj.value="";
}

thisForm.reset();
}
// -->
