i got a table which has fields in each row . if field is empty i want the particular row with red border around it.
<table cellpadding="3" cellspacing="5" >
<tr>
<td class="cellformatting"><label>first name*</label></td>
<td class="cellformatting"><input id="fname" type="text" class="required searchfields" />
</td>
</tr>
<tr>
<td class="cellformatting"><label>last name*</label></td>
<td class="cellformatting"><input id="lname" type="text" class="searchfields" /></td>
</tr>
</table>
i jst want the script if suppose last name is empty it should add some css around that particular row of table in which last name is shown.
How about something like this:
http://jsfiddle.net/kh6q8/
Here is a version which works without “Normalized CSS”, but the
cell-spacinghad to be removed:http://jsfiddle.net/kh6q8/2/