Hmm. It /should/ work.

Here is the complete code:

    $(document).ready(function() {
      $('tr').click(function(event) {
        $(this).toggleClass('click');
        if (event.target.type !== 'checkbox') {
          $(':checkbox', this).click();
        }
      });
    });

of course, you need to include the jquery.js file first, etc.

Here is a demo:

http://test.learningjquery.com/clickrow.html

--Karl

____________
Karl Swedberg
www.englishrules.com
www.learningjquery.com




On Dec 5, 2008, at 6:38 AM, Chizo wrote:


first, thanks! now...this is the code for the <tr>

$("tr").click(function() {
                        $(this).toggleClass("click");
                });
so, i suppose that here i should put the function to check the
checkbox, i tried with karl example but i can“t make it work...



Reply via email to