How to find the script tag's parent
<p>How to find an element relative to script's position? For instance, in the case below I would like <code>getSelfParent</code> to return the <code>$('button')</code> element</p>

<pre><code>&lt;button&gt;
    &lt;script&gt;
        getSelfParent().click(function(){...});
    &lt;/script&gt;
&lt;/button&gt;
</code></pre>

<p><code>$(this).parent()</code> did not work.</p>

<p>EDIT:</p>

<p>I want to avoid:</p>

<ul>
<li>adding ID's anywhere</li>
<li>traversing whole tree every time I am looking for the <code>self</code> element</li>
</ul>
