> For a Form Validation process, I need a function to avoid Latin characters > to be provided as the first or last name. Since we expect our users to > enter their personal info in Persian. > > Do you know any regular expression to provide this functionality? > 1) Regex to check whether there are Latin and Numerical characters in a > string. > 2) Regex to check whether the string only consists of certain characters. In a PCRE regex, [\x80-\xFF] will find all extended ASCII chars. Or, if you wanted all ASCII chars, you could use: [\x00-\xFF] That would catch space and punctuation as well though. Or you could amend it to suit. It's in hexadecimal (ie FF == 255) -- Richard Heyes HTML5 Graphing for FF, Chrome, Opera and Safari: http://www.rgraph.org (Updated November 1st) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php