How to get the uri of the .js file itself
<p>is there a method in JavaScript by which I can find out the path/uri of the executing script.</p>

<p>For example:</p>

<ol>
<li><p><code>index.html</code> includes a JavaScript file <code>stuff.js</code> and since <code>stuff.js</code> file depends on <code>./commons.js</code>, it wants to include it too in the page. Problem is that <code>stuff.js</code> only knows the relative path of <code>./commons.js</code> from itself and has no clue of full url/path.</p></li>
<li><p><code>index.html</code> includes <code>stuff.js</code> file as <code>&lt;script src="http://example.net/js/stuff.js?key=value" /&gt;</code> and <code>stuff.js</code> file wants to read the value of <code>key</code>. How to?</p></li>
</ol>

<p><em>UPDATE</em>: Is there any <strong>standard</strong> method to do this? Even in draft status? (Which I can figure out by answers, that answer is "no". Thanks to all for answering).</p>
