I'm wearing glasses too!

Your solution seems interesting but how be sure the replace method
match all possile accented chars typoing by the user?
And how invalidate blanks, spaces, symbols, number?
I'm not sure to understand very well your suggest...

In any case, great thanks to interest of my problem!

Aurélien

On 9 avr, 17:25, grigri <[EMAIL PROTECTED]> wrote:
> > Grigri, my first example is exactly what you said and it doesn't
> > work...
>
> Heh you're right, sorry - I was looking at the one that "almost"
> works...
>
> > Do you need some glasses ;o))
>
> Already wearing them!
>
> I've had a think, though - instead of doing a simple regexp, try using
> a custom validation method that does the following:
>
> * replaces accented chars with non-accented chars [adapt code from
> Mariano's Sluggable behavior - handles UTF-8 and latin1 (I think) ]
> * validates the result against normal alphaNumeric regexp
>
> Of course you don't want to *change* the data in the model, just
> change the string that is matched.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to