title: How to make a single button appear on only 1 jquery function
body: <p>I have a button called add to profile, all I need to know is how do I make it so its only on the last jQuery div, after the last next.</p>
  
  <p>Like question 1, then next, question 2 back and next, question 3, back and add button.
  So if you can really help me out here quick I'd really appreciate it.</p>
  
  <p>Here's my code:</p>
  
  <pre><code>&lt;script&gt;
  $(document).ready(function () {
  var oldOption;
  var counter = 1;
  var maxThings = 4;
  var minThings = 1;
  $("#2").hide();
  $("#3").hide();
  $("#4").hide();
  $('#back').hide();
  
  $("#forward").click(function () {
      $("#1").hide();
      $("#2").hide();
      $("#3").hide();
      $("#4").hide();
      if (!(counter &gt;= maxThings)) {
          counter++;
      }
      $("#" + counter).show();
      $('#back').show();
      if (counter === maxThings) {
          $('#forward').hide();
      }
  });
  
  $("#back").click(function () {
      $("#1").hide();
      $("#2").hide();
      $("#3").hide();
      $("#4").hide();
      if (!(counter &lt;= 1)) {
          counter--;
      }
  
      $("#" + counter).show();
      $('#forward').show();
      if (counter === minThings) {
          $('#back').hide();
      }
  
  });
  });
  &lt;/script&gt;
  </code></pre>