• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: How to extract the email address in a the message body
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to extract the email address in a the message body


  • Subject: Re: How to extract the email address in a the message body
  • From: Joseph Weaks <email@hidden>
  • Date: Mon, 8 Nov 2004 09:43:03 -0600


On Nov 8, 2004, at 7:44 AM, Randal L. Schwartz wrote:

"Leon" == Leon Chen <email@hidden> writes:

Leon> I do not mean those addresses in the header. I am looking at picking
Leon> up those within the message body which i believe need a certain
Leon> search mechanism called from Applescript. not sure it can be done.


"Email addresses in text with unknown boundary delimiters" is an
extremely difficult problem, mostly because email addresses are
incredibly complex.  For example, you'd have to locate


merlyn (that is me) @ stonehenge (not the one in england, the other one) . (that is a dot!) com

Yes, all on separate lines. That's a valid email address. Even with
the comments. So is this-- fred&email@hidden and it's an auto
responder, so go ahead and try it. But wait... was the "this--"
part of the email address or not? You can't tell! The delimiters
are not inherent in the message.


So, if your problem is narrower than that, it might help to narrow
down what you are willing to look for and willing to reject.

How is "this-- part of the addy? You can't have a space in a valid addy.
Well, if this guy ISN'T doing a project for NASA and CAN lower his standards a bit. Just find every occurrence of "@" that's not immediately next to punctuation or whitespace, and then capture all the text between the space before the "@" and the space after it. That will capture most of the standard and URL formats, what, like 99.sumthin% of them?
It will also capture other uses of the "@", so just allow for that.


Joe Weaks

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: How to extract the email address in a the message body
      • From: Bernardo Hoehl <email@hidden>
    • Re: How to extract the email address in a the message body
      • From: email@hidden (Randal L. Schwartz)
References: 
 >How to extract the email address in a the message body (From: Leon Chen <email@hidden>)
 >Re: How to extract the email address in a the message body (From: Daniel Todd Currie <email@hidden>)
 >Re: How to extract the email address in a the message body (From: Leon Chen <email@hidden>)
 >Re: How to extract the email address in a the message body (From: email@hidden (Randal L. Schwartz))

  • Prev by Date: Re: address book: find out whether the selection contains persons or groups
  • Next by Date: Re: How to extract the email address in a the message body
  • Previous by thread: Re: How to extract the email address in a the message body
  • Next by thread: Re: How to extract the email address in a the message body
  • Index(es):
    • Date
    • Thread