title: call .js file in joomla template
body: <p>I'm creating a joomla template.
  I've loaded jquery with this code in my index.php:</p>
  
  <pre><code>JHtml::_('jquery.framework');
  </code></pre>
  
  <p>and then I created animate.js in js folder that includes this script:</p>
  
  <pre><code>&lt;script&gt; jQuery("#content").ready(function(){
  
  jQuery("#content").animate({opacity:'0.4'});
  
  }); &lt;/script&gt;
  </code></pre>
  
  <p>and I added </p>
  
  <pre><code>&lt;script type="text/javascript" src="templates/basicjoomla3.0template/js/animate.js"&gt;&lt;/script&gt;
  </code></pre>
  
  <p>in head section of index.php but it doesn't work.
  When I use my script in body tag of index php it works successfully but when I want to load it from js file it doesn't work.
  What should I do now?
  Thanks for your help.</p>