ES wrote:
> What would the reg expression be for a string of 13 consecutive digits
> in javascript?
>
> var textfieldIdRegexp = /^\d{13}/;
Do you mean a string matching exactly 13 digits?
/^\d{13}$/
Or, a string containing a 13 digit sequence?
/\d{13}/
Or, string starting with 13 consecutive digits?
/^\d{13}/ (What you showed in your post.)
--
Posted via http://www.ruby-forum.com/.
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en.