i am using jsp for registration form. I use servlet for verification of existing username. how can i write client side validation code in javasript. My registration form is
<form action="Registration" method="post" name="registration" >
<table>
<tr>
<td>Name</td>
<td>:<input type="text" name="name" value="" placeholder="Name"
class="input_Name"></td>
</tr>
<tr>
<td>Place</td>
<td>:<input type="text" name="place" value="" placeholder="Place"
class="input_Place"></td>
</tr>
<tr>
<td>Gender</td>
<td>:<input type="radio" value="male" name="gender">Male
<input type="radio" value="female" name="gender">Female</td>
</tr>
<tr>
<td>UserName</td>
<td>:<input type="text" name="username" value="" placeholder="UserName"
class="input_UserName"></td>
</tr>
<tr>
<td>Password</td>
<td>:<input type="password" name="password" value="" placeholder="Password"
class="input_Password"></td>
</tr>
<tr>
<td>Confirm sword</td>
<td>:<input type="password" name="password" value="" placeholder="re-
Password" class="input_re-Password"></td>
</tr>
<tr>
<td></td>
<td><input type="submit" value="submit" ></td>
</tr>
</table>
</form>
thank you..