Forum Moderators: coopster

Message Too Old, No Replies

problem with ctype alpha function

Return false where unexpected

         

dbarasuk

12:28 pm on Nov 27, 2009 (gmt 0)

10+ Year Member



Hi,
I used the ctype_alpha to check if my string contained only letters. But it happened that the keyboard i was using had no some accentuated french characters like é or è. So used alt+number on the numeric side of the keyboard. Apart from the fact that i used the numeric part of the keyboard to get the characters i was using, the function returned FALSE for a name like "Aimé". For me it would return TRUE.
How can you explain this? All the characters are alphabetic!

bkeep

11:15 pm on Nov 27, 2009 (gmt 0)

10+ Year Member



If you look at the php manual page for ctype_alpha there are two comments that relate to your issue.

[php.net...]