On Tue, Jul 22, 2008 at 1:23 PM, Wayne Shao <[EMAIL PROTECTED]> wrote:
> I want to parse our the user's name from email address such as
>      "Joe Smith" <[EMAIL PROTECTED]>

Do be careful; I'm reasonably sure that it is impossible to express
all valid email addresses with a regex.  And if it is possible, it's
very, very complicated.  So you may not really want to accept only
valid email addresses.  Also, the presence of quotation marks is going
to make a proper regex very difficult.  You might be better off
implementing a tiny state machine.

--Kyle Sluder
_______________________________________________

Cocoa-dev mailing list ([email protected])

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]

Reply via email to