Posted By

chrisaiv on 08/27/12


Tagged

html5


Versions (?)

HTML5: Input box with regular expressions


 / Published in: HTML
 

If I ever need a regular expression for $99.99. Here it is.

  1. <input type="text" pattern="^\$?([0-9]{1,3},([0-9]{3},)*[0-9]{3}|[0-9]+)(.[0-9][0-9])?$" name="widgetprice" id="widgetprice" size="25" value="<%= widget.price %>" required/>

Report this snippet  

You need to login to post a comment.