title: Input data into table and auto sort
body: <p>I am trying to figure out this simple problem. I want to have the user be able to input data and then the data automatically sorts in ascending order to whatever has already been submitted in the table. I'm stuck on the auto-sorting part. Here is my JS Fiddle
  <a href="http://jsfiddle.net/6n4kugbp/" rel="nofollow">http://jsfiddle.net/6n4kugbp/</a></p>
  
  <p>HTML</p>
  
  <pre><code>&lt;input id="id_name" name="numid"/&gt;
  &lt;input id="id_age" name="price"/&gt;
  &lt;button id="add_btn"&gt;click&lt;/button&gt;
  
  &lt;table border="1" class="mytab"&gt;&lt;/table&gt; 
  </code></pre>
  
  <p>Jquery</p>
  
  <pre><code>$("#add_btn").on('click', function(e) {
      e.preventDefault();
      var name = $('#id_numid').val(), 
          age = $('#id_price').val();
  
      $('&lt;tr&gt;&lt;td&gt;'+numid+'&lt;/td&gt;&lt;td&gt;'+price+'&lt;/td&gt;&lt;/tr&gt;').appendTo( $('.mytab') );
  });
  </code></pre>