Jquery comparing elements
<p>I have an array on javascript and i insert the elements on it like this:</p>

<pre><code> var parentRow = $(button).parent().parent();
 list.push({ parent: parentRow, detailRow: newRow });
</code></pre>

<p>On the click of another button i do the following:</p>

<pre><code>      var parentRow = $(button).parent().parent();
      var detailRow = null;

      for (var i in list) {
        if ($(list[i].parent) == $(parentRow)) {
          detailRow = list[i].detailRow;
        }
      }
</code></pre>

<p>The point is: The if comparing to two elements should return TRUE, because they are the same DOM element....the same i added before, but it return FALSE.</p>

<p>I would like to know how i compare this two elements to get TRUE there.</p>
