Hey,
My problem is that focus to filed happens and un focuses soon after that , however i want it to persist till user resubmits , i am using the following
<html>
<head>
<script language="javascript">
function fnc_Validate()
{
var str= '';
if(document.getElementById('name1'))
{
if(document.getElementById('name1').value == '')
{
alert('Cannot be left Blank');
document.getElementById('name1').focus();
return false;
}
}
str = "Short1.php";
document.frmname.action = str;
document.frmname.submit();
}
</script>
</head>
<body>
<form name='frmname' method='post'>
<input type="text" name="name1" id="name1">
<input type="text" name="name2" id="name2">
<input type="text" name="name3" id="name3">
<input type="submit" value="shorten" onclick="fnc_Validate();">
</form>
</body>
</html>
Any help would be great , thanks