iphone - email authentications -
is any example to authenticate e-mail addresses in a Aepiai or iPhone app that can give me tips
You need to use regular expressions to check email validation.
You can do a simple test:
NSString * emailRegEx = @ "(?: [A-z0-9! # $% \\ & amp; + / =? \\ ^ _
{|} ~ -] + (?: \. [a-Z0-9! # $% \ & amp; '* + / =? \ ^ _ {|} "@" ~ -] +) * | \ "(?: [\\ Ks0l - \\ Ks08 Ks0b \\ \\ \\ Ks0c Ks0e - Kslf \\ \\ \\ Ks2l Ks23 - \\ Ks5b \ \ X5d - \\ "@" x7f] | \\\\ [\\ x01 - \\ x09 \\ x0b \\ x0c \\ x0e - \\ x7f] * \ ") @ (?: (?: [A -z0- 9] (?: [a- "@" z0-9-] * [A-Z0-9]) \\) + [A-Z0-9] ([a-Z0-9 -] * [ One-Z0-9]). \\ [(?. ?? :(?: 25 [0-5 "@"] | 2 [0-4] [0-9] | [01] [0-9] [0- 9]?) \\.) {3} (?: 25 [0-5] | 2 [0-4] [0-9] | [01]? [0- "9" [9] [ 0-9]? | [A-J 0-9 -] * [A-z0- 9]: (?: [\\ x01 - \\ x08 \\ x0b \\ x0c \\ x0e - \\ x1f \\ Ks2l "@" - \\ \\ Ks5a Ks53 - \\ Ks7f] | \\\\ [\\ Ks0l - \\ Ks09 Ks0b \\ \\ \\ Ks0c Ks0e - \\ Ks7f]) +) \\]) ";
NSPredicate * regExPredicate = [NSPredicate predicateWithFormat: @" Self-mat HES% @ ", EmailRegEx];
BOOL myStringMatchesRegEx = [regExPredicate evaluation with object: myString];
The only question that remains: What is a regular expression that can be used to verify that there is a syntactically valid email address in an NSString?
Comments
Post a Comment