I am trying to write some form validation, I need one of the inputs to be 1-9999. I know nothing about regular expressions ( never used them before) and here is my first attempt
This doesn't exclude zero, but /^\d{1,4}$/ should do the trick.
/^\d{1,4}$/