Welcome to TSDN!
What do you mean by 'indentation of 4 instead of 1'?
Do you get some sort of error?
i tried checking the function with a
js-verifier and got this error..
Problem at line 3 character 2: Expected 'with' to have an indentation of 4 instead of 1.
with (window.document.frmAddUser) {
while on firefox error console it says,
Error: window.document.frmAddUser has no properties
this is my form..
[HTML]<form action="processUser.php?action=add" method="post" enctype="multipart/form-data" name="frmAddUser" id="frmAddUser"">
<table width="100%" border="0" align="center" cellpadding="5" cellspacing="1" class="entryTable">
<tr>
<td width="150" class="label">User Name</td>
<td class="content"> <input name="txtUserName" type="text" class="box" id="txtUserName" size="20" maxlength="20"></td>
</tr>
<tr>
<td width="150" class="label">Password</td>
<td class="content"> <input name="txtPassword" type="password" class="box" id="txtPassword" value="" size="20" maxlength="20"></td>
</tr>
</table>
<p align="center">
<input name="btnAddUser" type="button" id="btnAddUser" value="Add User" onClick="checkAddUserForm();" class="box">
<input name="btnCancel" type="button" id="btnCancel" value="Cancel" onClick="window.location.href='index.php';" class="box">
</p>
</form>[/HTML]