[Zope] FindOneOf?

Chris Withers chrisw@nipltd.com
Thu, 27 Jul 2000 20:55:19 +0100


"Mabe, Brad" wrote:
> Will return a "4" because "d" is the fourth letter in the string
> "abcdefghij".  If no match is made, a 0 is returned.  This is especially
> useful when building a change password form, because I can easily check to
> see that the new password contains at least one special character, upper
> case character, number, etc.  

<dtml-if "not 'x' in 'xyz'">
You haven't got an 'x' in your stuff
<dtml-else>
Yay!
</dtml-if>

That'll do for starters, you might want to look into the python re
module (you'll need an external method as I don't think python methods
support re...)

cheers,

Chris