Get attr('id') from a <td> using jQuery
<p>I have the following code, and the checkb starts from checkb01 to chekb342.</p>

<pre><code>&lt;tr&gt;
     &lt;td class="specs_under"&gt;Specs&lt;/td&gt;
     &lt;td id="checkb77" class='checkb'&gt;&lt;input type="checkbox" id="add_remove77" class="change_image77"/&gt;&lt;/td&gt;
     &lt;td  class="specs_under_value" id="specs_unit77"&gt;1&lt;/td&gt;
     &lt;td rowspan="13" class="specs_under_value" id="specs_itempr77"&gt;15&lt;/td&gt;
     &lt;td class="specs_under_value" id="specs_quantity77"&gt;&amp;nbsp;&lt;/td&gt;
     &lt;td class="specs_under_value" id="specs_packageprice77"&gt;0.125&lt;/td&gt;
&lt;/tr&gt;
</code></pre>

<p>I tried using  this code</p>

<pre><code>$(document).ready(function(){
    $(".checkb").toggle(function() {
        var cid = $(this).attr('id');
        alert('id');

    },function() {
        alert('checkbox unchekced');

    }
</code></pre>

<p>How do I get the value of the id in <code>&lt;td&gt;</code> respective checkbox clicks using jquery</p>

<p>Thanks
Jean</p>

<p><strong>Guys I need to get the value of  id  when the checkbox is clicked, not the checkbox id</strong></p>
