title: jQuery. Bootstrap wizard not going to next step
body: <p>I am using a bootstrap wizard but when you click on the next step, it's not going forward .
   I am trying to make it go all the way and enable the previous once it reaches the end.</p>
  
  <p>For some reason its not working correctly</p>
  
  <p>my <a href="https://jsfiddle.net/dev2020/v1ruxwkw/6/" rel="nofollow noreferrer">FIDDLE</a></p>
  
  <pre><code>$(document).ready(function() {
  
      var navListItems = $('ul.setup-panel li a'),
          allWells = $('.setup-content');
  
      allWells.hide();
  
      navListItems.click(function(e)
      {
          e.preventDefault();
          var $target = $($(this).attr('href')),
              $item = $(this).closest('li');
  
          if (!$item.hasClass('disabled')) {
              navListItems.closest('li').removeClass('active');
              $item.addClass('active');
              allWells.hide();
              $target.show();
          }
      });
  
      $('ul.setup-panel li.active a').trigger('click');
  
  
      $('#activate-step-2').on('click', function(e) {
          $('ul.setup-panel li:eq(1)').removeClass('disabled');
          $('ul.setup-panel li a[href="#step-2"]').trigger('click');
          $(this).remove();
      })    
       $('#activate-step-3').on('click', function(e) {
          $('ul.setup-panel li:eq(1)').removeClass('disabled');
          $('ul.setup-panel li a[href="#step-3"]').trigger('click');
          $(this).remove();
      })  
  
  });
  </code></pre>