Using a substring function along with jQuery?
<p>I have the following HTML that can appear but only one at a time:</p>

<pre><code>&lt;a id="menuRange" class="button" href="#"&gt;1 - 100&lt;/a&gt;
&lt;a id="menuRange" class="button" href="#"&gt;101 - 200&lt;/a&gt;
&lt;a id="menuRange" class="button" href="#"&gt;201 - 300&lt;/a&gt;
</code></pre>

<p>and I used this code to get the range: </p>

<pre><code>var $field = $('#menuRange');
var nums = $field.text().split('-').map(function (a) {
    return parseInt(a, 10) + d * 100
});
</code></pre>

<p>Now I want to change the HTML into:</p>

<pre><code>&lt;a id="menuRange" class="button" href="#"&gt;Lines 1 - 100&lt;/a&gt;
&lt;a id="menuRange" class="button" href="#"&gt;Lines 101 - 200&lt;/a&gt;
&lt;a id="menuRange" class="button" href="#"&gt;Lines 201 - 300&lt;/a&gt;
</code></pre>

<p>How can I make it so I still get nums data like before. In other words, how
can I make it ignore the word "Lines " as though it was not there?</p>
