Fast Secure Contact Form
Validation Regex (3 posts)

  1. bkss
    Posted 4 years ago #

    I want the user to enter a rating-value with dots instead of comma, for example 1.234 not 1,234.
    How do a "force" the submitter to this?
    The string /^\d+$/ does not allow to use either comma or dot, only digits.

    Is there a validation regex that I can use instead?


  2. Mike Challis
    Plugin Author

    Posted 3 years ago #

    of course there's the validation regex for anything, you just have to write it ;)


  3. bkss
    Posted 3 years ago #

    I've tried your proposal and it works fine!
    I assumed that it was quite easy to fix, but could not figure that out based on the string /^\d+$/. And google could also not help me! :-)

    Thanks a lot for your help!

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Fast Secure Contact Form
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic