Substrings in Javascript with substr()
<p>I need to use Substring in Javascript. But despite my searches, i have an error : substr seems to be unknown...</p>

<pre><code>function confirm_ticket(idAgir,TempsEstime) {

    var str = TempsEstime;
    var strConcatenate = TempsEstime.substr(0, 2) + ":" + TempsEstime.substr(2, 2);

    alert("confirmer le temps de maintenance de " + strConcatenate + " min pour le ticket " + idAgir);
}
</code></pre>

<p>Is there anything wrong in this ?
thanks in advance</p>
