Decimal separator


Author
Message
Dave
Dave
Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)
Group: Administrators
Posts: 13K, Visits: 104K
Yes, a regular expression in the /mask attribute should do the trick:

/ mask = ^[0-9]+$

teilai
teilai
Partner Member (962 reputation)Partner Member (962 reputation)Partner Member (962 reputation)Partner Member (962 reputation)Partner Member (962 reputation)Partner Member (962 reputation)Partner Member (962 reputation)Partner Member (962 reputation)Partner Member (962 reputation)
Group: Forum Members
Posts: 8, Visits: 91
I want to constrain the participant input in a textbox to positive integers or zero, and use a corresponding mask "positiveintegerorzero."
However, it does not work if one uses a comma as a decimal separator (as people here in Europe do), and inputs such as 0,500 are happily accepted.
This is not a major problem, but if anyone knows a quick solution (to use a regular expression?), I'd like to see it.

Thanks,


GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Reading This Topic

Explore
Messages
Mentions
Search