[thelist] numeric only regex?
Tom Dell'Aringa
pixelmech at yahoo.com
Tue Aug 2 15:58:23 CDT 2005
--- Christian Heilmann <codepo8 at gmail.com> wrote:
> Try var match=/^[0-9]$/.test(numtext);
> this checks for 1 digit in the range 0-9 inclusive.
Great, except I need any number of digits - would it be:
var match=/^[0-9]*$/.test(numtext); ?
I'm not sure where to put the * - if I put it in the beginning I get a comment of course.
Tom
http://www.pixelmech.com/
Melissa: Ace, Where are you?
Ace Ventura: I'm in Psychoville and Finkle's the Mayor.
More information about the thelist
mailing list