[jQuery] Validation
[jQuery] Validation
How to validate a portion of a form
In my html form I have 100 fields which I have divided them in 3
tabs, When the user leaves the tab we need to validate the tab. How do
I need to validate the data which is in each div tag
Here is the sample code
<!-- This is tab 1 ---->
<div class="fragments" id="fragment-1">
<table>
<tr>
<td>
First Name :
</td>
<td>
<input type="text" name="firstName">
</td>
</tr>
<tr>
<td>
Last Name :
</td>
<td>
<input type="text" name="lastName">
</td>
</tr>
</table>
</div>
<!-- This is tab 2 ---->
<div id="fragment-2">
<table>
<tr>
<td>Phone Number :</td>
<td><input type="text" name="phoneNumber"></td>
</tr>
<tr>
<td>Email :</td>
<td><input type="text" name="email"></td>
</tr>
</table>
</div>
<!-- This is tab 3 ---->
<div id="fragment-3">
<table>
<tr>
<td>
Street :
</td>
<td>
<input type="text" name="street">
</td>
</tr>
<tr>
<td>
Zip Code :
</td>
<td>
<input type="text" name="zip">
</td>
</tr>
</table>
</div>