Finding "position" in DOM of clicked link
<p>I have a page with a number of links with a class called "myLinkClass". These links can reside in one of two DOM structures:</p>

<pre><code>&lt;div class="divClassA"&gt;
    &lt;a class="myLinkClass" ...
&lt;/div&gt;
</code></pre>

<p>or</p>

<pre><code>&lt;div class="divClassB"&gt;
    &lt;a class="myLinkClass" ...
&lt;/div&gt;
</code></pre>

<p>I hook up the click event of the links with the class to an event handler with jQuery:</p>

<pre><code>$(document).ready(function () {
    $('.myLinkClass').bind('click', function (event) {
        //...
    });
});
</code></pre>

<p><strong>How can I find out if the clicked link is inside a divClassA or a divClassB?</strong> </p>

<p>Note that although the links are immeditate childrens to the divs in the examples above, that might not be the case. Also, there might be an arbitrary number of both divClassA and divClassB (not just one of each).</p>
