1

How can I input in the textbox and only accept numbers and symbols without use maskedinput?

eg : 12345-12

Bill the Lizard
  • 398,270
  • 210
  • 566
  • 880
user575462
  • 17
  • 2

3 Answers3

1

You might try this approach: How to allow only numeric (0-9) in HTML inputbox using jQuery?

Or perhaps: http://roshanbh.com.np/2008/04/textbox-accept-only-numbers-digits.html

Community
  • 1
  • 1
keybored
  • 5,194
  • 13
  • 45
  • 70
0

use a validation library and tweak the regex so that it matches what you want. i like this library. :)

melaos
  • 8,386
  • 4
  • 56
  • 93