title: Include a JS file using jQuery
body: <p>I actually have a problem with including JS file using jQuery. I found many sources but no one work with me. I'm pretty sure that the path of the js file is right. These are my two tries :</p>
  
  <p>The first one (which I prefer) is working with <code>&lt;link&gt;</code> (to include CSS files) but it's not working with <code>&lt;script&gt;</code> tags.</p>
  
  <pre class="lang-js prettyprint-override"><code> $('head').append('&lt;script type="text/javascript" src="'+addon+'"&gt;&lt;/script&gt;');
  </code></pre>
  
  <p><br/>
  And the second one is by using get HTTP request. And here is my try :</p>
  
  <pre class="lang-js prettyprint-override"><code> $.getScript(addon, function(){});
  </code></pre>
  
  <p><br/>
  So, the question is: what is wrong with the first code? Because I tried it before with <code>&lt;link&gt;</code> tags and its working so good.</p>