Why is the rowIndex property of a jQuery returned element.parents("tr") row undefined?
<p>If i get a reference to an elements parent as follows:</p>

<pre><code>function findParentRow(srcElement) {
    var curElement = srcElement;
    while (curElement &amp;&amp; (curElement.tagName != "TR")) {
        curElement = curElement.parentElement;
    }
    return (curElement.tagName == 'TR' ? curElement : null);
}
</code></pre>

<p>I can:</p>

<pre><code>var parentRow = findParentRow(someElement);
alert(parentRow.rowIndex);
</code></pre>

<p>and I will get a rowIndex alert. But if i:</p>

<pre><code>var parentRow = $(chkBox).parents("tr");
</code></pre>

<p>I can </p>

<pre><code>alert(parentRow);
</code></pre>

<p>and get an object but if i </p>

<pre><code>alert(parentRow.rowIndex);
</code></pre>

<p>I get undefined. Instead i have too:</p>

<pre><code>alert($(pRow).attr("rowIndex"));
</code></pre>

<p>to get an index. </p>

<p>Why is this?</p>
