On Mon, 11 Mar 2002, Charlie Watts wrote: > On Mon, 11 Mar 2002, Matt Sergeant wrote: > > <snip/> > > > > Wouldn't an easier fix be: > > > > /^([A-Z]|[^a-z])*$/ > > That's just way too simple, Matt. Let's try for something more > complicated. :-) > > But it doesn't have the "must have at least XX characters" element that > the other test has. Does that matter? I'm not sure.
It's pretty likely that it doesn't matter since the other regexp was obviously quite broken anyway ;-) I think the original intention of the count was to make sure we had at least three upper case chars, in which case you could get away with: /^([A-Z]|[^a-z])*?[A-Z]{3,}([A-Z]|[^a-z])*$/ That needs testing though to make sure it doesn't backtrack horribly (I don't think it will, but I could be wrong). -- Matt. <:->get a SMart net</:-> ________________________________________________________________________ This e-mail has been scanned for all viruses by Star Internet. The service is powered by MessageLabs. For more information on a proactive anti-virus service working around the clock, around the globe, visit: http://www.star.net.uk ________________________________________________________________________ _______________________________________________ Spamassassin-talk mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/spamassassin-talk