JQuery Select Empty Child Element

From CoderLearner
Jump to: navigation, search


$(':empty') is the empty selector to select element that it is empty.

Example 1

<!DOCTYPE html>
      <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
         $(document).ready(function() {
            <td></td> <!-- empty -->
            <td></td><!-- empty -->
            <td></td><!-- empty -->
            <td></td><!-- empty -->

Try It

<seo metagenerator="jquery tutorial" title="Jquery/Ajax" metakeywords="jquery greater,jquery gt, jquery lt, less then, odd jquery,jquery find element, even jquery,jquery event, jquery mouse click, jquery double click, jquery hover, jquery string, jquery array, jquery button, jquery attriubtes" metadescription="jquery button, jquery attriubte, jquery example, jquery tutorial, jquery sample"/>