title: How to get the absolute path of the current javascript file name
body: <p>I have a javascript file named <code>main.js</code>.</p>
  
  <p>Inside <code>main.js</code> I want to get the absolute path of this current file, something like:</p>
  
  <pre><code>http://server/app/main.js
  
  http://server/app/script/main.js
  </code></pre>
  
  <p>What is the fastest way to get the absolute path?</p>