S
Showjumper
Hi,
I am using ASP.NET AJAX to check username availability in a registration
form. Everything works fine in IE but not in FF. Using Firebug, i can find
the offending line but not sure what to about it. The error firebug gives
txtUsername has no properties. Not sure how to fix this. Thank you for any
help.
var txtUserName;
function pageLoad()
{
txtUserName = $get("<%=Username.UniqueID %>");
}
function CheckUserName()
{
if (txtUserName.value.length > 0)
{
$get("imgWaitingUsername").style.display = 'inline';
$get("spanUsername").innerHTML = 'Checking Username Availability...';
$get("spanUsername").style.color = "red";
$get("spanUsername").style.fontWeight = "bold";
PageMethods.CheckUserName(txtUserName.value, OnCheckUserName);
}
else
$get("spanUsername").innerHTML= "";
reqvalUsername.innerHTML = "Username is required";
}
I am using ASP.NET AJAX to check username availability in a registration
form. Everything works fine in IE but not in FF. Using Firebug, i can find
the offending line but not sure what to about it. The error firebug gives
txtUsername has no properties. Not sure how to fix this. Thank you for any
help.
var txtUserName;
function pageLoad()
{
txtUserName = $get("<%=Username.UniqueID %>");
}
function CheckUserName()
{
if (txtUserName.value.length > 0)
{
$get("imgWaitingUsername").style.display = 'inline';
$get("spanUsername").innerHTML = 'Checking Username Availability...';
$get("spanUsername").style.color = "red";
$get("spanUsername").style.fontWeight = "bold";
PageMethods.CheckUserName(txtUserName.value, OnCheckUserName);
}
else
$get("spanUsername").innerHTML= "";
reqvalUsername.innerHTML = "Username is required";
}