jquery access sibling TD in table

Posted by Rob on Stack Overflow See other posts from Stack Overflow or by Rob
Published on 2010-05-22T22:16:12Z Indexed on 2010/05/22 22:20 UTC
Read the original article Hit count: 480

Filed under:
|
|
|

I have the following HTML Code. What I'm try to do is to have the div named javaRatingDiv to be displayed once the checkbox with the name java is checked.

I can't seem to figure out how to navigate to the next TD in a table via jquery.

<div id="languages">
   <table style="width:inherit">
   <tr style="height:50px; vertical-align:top">
     <td>Select the languages that you are familiar with and rate your knowledge:</td>
   </tr>
   <tr>
     <table style="width:75%;" align="center">   
     <tr id="tableRow"> 
       <td id="firstTD"><input type="checkbox" name="java" value="java" />&nbsp;Java</td>
       <td id="secondTD" style="width:200px;">
         <div id="javaRatingDiv" style="display:none">
           <input name="javaRating" type="radio" value="1" class="star"/>
           <input name="javaRating" type="radio" value="2" class="star"/>
         </div>
       </td>
     </tr>
     </table>
    </tr>
    </table>
</div>

© Stack Overflow or respective owner

Related posts about jQuery

Related posts about td