How to Append Table row with specific Number in jquery
<p>I have a table and a class = Add that appends rows when clicked and a class = number. </p>

<p>My question is how can I append my rows with the number that stored in the span with class number? </p>

<p>Here is my snippet :</p>

<p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
<div class="snippet-code">
<pre class="snippet-code-js lang-js prettyprint-override"><code>$(document).ready(function () {
  $(".add").click(function () {
    $('#mytable tr:last').after('&lt;tr&gt;&lt;td class="tr1" style="max-width: 10px;"&gt;Hello&lt;/td&gt;&lt;/tr&gt;');
  });
})</code></pre>
<pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;script src="https://ajax.googleapis.com/ajax/libs/jquery/1.2.3/jquery.min.js"&gt;&lt;/script&gt;
You can add &lt;span class="number"&gt; 3&lt;/span&gt; Hosts 
&lt;table id="mytable" border="1"&gt;
   &lt;tr&gt;
      &lt;td&gt;1&lt;/td&gt;
      &lt;td&gt;Title&lt;/td&gt;
      &lt;td&gt;price&lt;/td&gt;
   &lt;/tr&gt;
   &lt;tr&gt;
      &lt;td&gt;1&lt;/td&gt;
      &lt;td&gt;Title &lt;/td&gt;
      &lt;td&gt;price&lt;/td&gt;
    &lt;/tr&gt;
&lt;/table&gt;
&lt;span  class="add" data-tooltip="You can add 3 host"&gt;&lt;font color="red"&gt;add+&lt;/font&gt;&lt;/span&gt;</code></pre>
</div>
</div>
</p>