W3C home > Mailing lists > Public > whatwg@whatwg.org > October 2005

[whatwg] Re: Web Forms 2.0

From: Ryan Cannon <ryan@ryancannon.com>
Date: Fri, 7 Oct 2005 15:21:17 -0400
Message-ID: <40484F4C-A50D-4543-963F-53E301629AB9@ryancannon.com>

In attempting to write a javascript implementation of Web Forms 2.0  
attributes, I came across a stumbling block. At times, form  
validation requires a "not pattern" result, i.e. if a certain pattern  
matches the element value, the validation engine should return an  
error. The best real-world example of this type of implementation  
would be a form field with an initial value that must be changed in  
order to be processed as valid.

I would suggest an attribute name notPattern, implemented as a  
reverse of the pattern attribute.


<input type="text" required="required" notPattern="First Name\s*"  
value="First Name" />

I hope it is not too late in this versions timeframe to bring such  
functionality in, as it seems impossible right now.

Ryan Cannon

Wordslinger, Webwright
Received on Friday, 7 October 2005 12:21:17 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 16:58:43 UTC