how to select which doesn't has any input child
- <!DOCTYPE html>
- <html>
- <head>
- <script src="js/jquery-1.4.2.min.js"></script>
- </head>
- <body>
- <table width="100%" border="1">
- <thead>
- </thead>
- <tbody>
- <tr>
- <td>
- <input type="checkbox" id="del[]" value="1">
- </td>
- <td>alert</td>
- <td>alert</td>
- </tr>
- <tr>
- <td>
- <input type="checkbox" id="del[]" value="2">
- </td>
- <td>alert</td>
- <td>alert</td>
- </tr>
- </tbody>
- <tfoot>
- </tfoot>
- </table>
- </body>
- <script>
- $('tbody > tr > td').not(children('input')).click(function()
- { alert('Doesn't has an input child!');
- });
- </script>
- </html>