[jQuery] Re: Input that allows only numbers.

2009-07-17 Thread Matt Zagrabelny
On Thu, 2009-07-16 at 16:12 -0700, Caio Landau wrote: Well, that a simple question, I hope. I have an input (input type=text /) on my page, and I want it to only accept numbers, so if the user types anything that's not a number, it will be removed instantly. A simplified example just to

[jQuery] Re: Input that allows only numbers.

2009-07-17 Thread Caio Landau
So let me get it, key's code numbered between (and including) 48 and 57 are numbers? Ok, I got it, thank you :) On Jul 17, 11:18 am, Matt Zagrabelny mzagr...@d.umn.edu wrote: On Thu, 2009-07-16 at 16:12 -0700, Caio Landau wrote: Well, that a simple question, I hope. I have an input (input

[jQuery] Re: Input that allows only numbers.

2009-07-17 Thread Matt Zagrabelny
On Fri, 2009-07-17 at 08:45 -0700, Caio Landau wrote: So let me get it, key's code numbered between (and including) 48 and 57 are numbers? I used an alert dialog to determine the keycodes, you could probably also use an ascii chart. You also may want to include the codes for: backspace arrow

[jQuery] Re: Input that allows only numbers.

2009-07-17 Thread Cesar Sanz
try this http://www.texotela.co.uk/code/jquery/numeric/ - Original Message - From: Caio Landau wonho...@gmail.com To: jQuery (English) jquery-en@googlegroups.com Sent: Friday, July 17, 2009 9:45 AM Subject: [jQuery] Re: Input that allows only numbers. So let me get it, key's code