title: To pass the ID of DIV tag in JQuery
body: <p>I am learning JQuery.</p>
  
  <pre><code>&lt;Div ID="top"&gt;
  &lt;DIV ID="testing1"&gt;
  &lt;DIV ID="testing2"&gt;&lt;DIV ID="testing3"&gt;...&lt;DIV ID="testing100"&gt;&lt;/Div&gt;
  </code></pre>
  
  <p>Since there are tens of DIV tags with different ID generated by a PHP file
  And I am trying to pass a dynamic ID of a DIV tag to a JQuery self-defined function:</p>
  
  <pre><code>&lt;script&gt;$(function() {
   $("div").mouseover(function() {
        var ID = $(this).children().attr('id');
        alert(ID);     });}); &lt;/script&gt;
  </code></pre>
  
  <p>But it wont work.</p>