title: Page jumps down when tab is clicked once active
body: <p>So on the site <a href="http://stvplus.com" rel="nofollow">STVPlus</a> we use bootstrap and the tabs script to show episodes and articles lists for various tv shows. I am having an issue where once the page has loaded (usually) it works fine, you can select a tab and the appropriate div will show. However if you select an already active div the page jumps down.Also when loading the page with a hash tag like so <a href="http://stvplus.com/#episodes" rel="nofollow">episodes hash tag link</a>, then it automatically jumps down when page is fully loaded. I have tried stepping through the JS code using chrome dev tools, however I could not find anything obvious. </p>
  
  <p>Any help would be appreciated.</p>
  
  <p>Sample code:</p>
  
  <pre><code>$(function()
  {
      $('.sidebar').jScrollPane();
  
    // Bind an event to window.onhashchange that, when the hash changes, gets the
    // hash and adds the class "selected" to any matching nav link.
    $(window).hashchange( function(){
      var hash = location.hash;
  
  
      if ( hash == '#episodes'){
          //e.preventDefault();
          $('.nav-pills a:last').tab('show');
      }else{
          //e.preventDefault();
          $('.nav-pills a:first').tab('show');
      }
  
    })
  
    // Since the event is only triggered when the hash changes, we need to trigger
    // the event now, to handle the hash the page may have loaded with.
    $(window).hashchange();
    return false;
  });
  </code></pre>
  
  <p>the episodes div container is like so</p>
  
  <pre><code>&lt;div class="tab-pane" id="episodes"&gt;    ..... &lt;/div&gt;
  </code></pre>
  
  <p>and the tab you click is like so</p>
  
  <pre><code>&lt;ul class="nav nav-pills pull-right" data-tabs="tabs"&gt;
     &lt;li class="active"&gt;&lt;a href="&lt;?php echo current_url(); ?&gt;#articles"&gt;Latest Articles&lt;/a&gt;&lt;/li&gt;
     &lt;li&gt;&lt;a href="&lt;?php echo current_url(); ?&gt;#episodes"&gt;Upcoming Episodes&lt;/a&gt;&lt;/li&gt;
     &lt;/ul&gt;
  </code></pre>
  
  <p>I use the latest jquery, with <a href="http://benalman.com/projects/jquery-hashchange-plugin/" rel="nofollow">http://benalman.com/projects/jquery-hashchange-plugin/</a></p>