[imp] IMP 2.3 address books

Rich Lafferty rich@horde.org
Tue, 9 Oct 2001 15:51:58 -0400


On Tue, Oct 09, 2001 at 01:08:14PM -0400, Rich Lafferty (rich@horde.org) wrote:
> On Mon, Oct 08, 2001 at 12:35:13PM -0600, Lic. Rodolfo Gonzalez Gonzalez (rodolfo@equinoxe.g-networks.net) wrote:
> > 
> > I'm attaching a PHP class by Manuel Lemos which does it.
> 
> ...Poorly. You can't match an email address with a regular expression
> with a standard regular expression, as email addresses can contain
> nested comments.

Er, "You can't match an email address with a standard regular
expression, as ...". Sorry.

To make up for my mis-edit, I've included the regular expression that
matches RFC822 addresses except for nested comments below my
signature. Addresses are to be normalized to lowercase before matching.

  -Rich

-- 
Rich Lafferty --------------+-----------------------------------------------
 Ottawa, Ontario, Canada    |  Save the Pacific Northwest Tree Octopus!
 http://www.lafferty.ca/    |    http://zapatopi.net/treeoctopus.html
rich@lafferty.ca -----------+-----------------------------------------------

(?:[\040\t]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff]|\((?:[^\\\x80-\xff\n
\015()]|\\[^\x80-\xff])*\))*\))*(?:(?:[^(\040)<>@,;:".\\\[\]\000-\037\x80-\
xff]+(?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff])|"(?:[^\\\x80-\xff\n\015"
]|\\[^\x80-\xff])*")(?:(?:[\040\t]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xf
f]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff])*\))*\))*\.(?:[\040\t]|\((?:[
^\\\x80-\xff\n\015()]|\\[^\x80-\xff]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\
xff])*\))*\))*(?:[^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+(?![^(\040)<>@,;
:".\\\[\]\000-\037\x80-\xff])|"(?:[^\\\x80-\xff\n\015"]|\\[^\x80-\xff])*"))
*(?:[\040\t]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff]|\((?:[^\\\x80-\xff\
n\015()]|\\[^\x80-\xff])*\))*\))*@(?:[\040\t]|\((?:[^\\\x80-\xff\n\015()]|\
\[^\x80-\xff]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff])*\))*\))*(?:[^(\04
0)<>@,;:".\\\[\]\000-\037\x80-\xff]+(?![^(\040)<>@,;:".\\\[\]\000-\037\x80-
\xff])|\[(?:[^\\\x80-\xff\n\015\[\]]|\\[^\x80-\xff])*\])(?:(?:[\040\t]|\((?
:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80
-\xff])*\))*\))*\.(?:[\040\t]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff]|\(
(?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff])*\))*\))*(?:[^(\040)<>@,;:".\\\[\]
\000-\037\x80-\xff]+(?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff])|\[(?:[^\\
\x80-\xff\n\015\[\]]|\\[^\x80-\xff])*\]))*|(?:[^(\040)<>@,;:".\\\[\]\000-\0
37\x80-\xff]+(?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff])|"(?:[^\\\x80-\xf
f\n\015"]|\\[^\x80-\xff])*")(?:[^()<>@,;:".\\\[\]\x80-\xff\000-\010\012-\03
7]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff]|\((?:[^\\\x80-\xff\n\015()]|\
\[^\x80-\xff])*\))*\)|"(?:[^\\\x80-\xff\n\015"]|\\[^\x80-\xff])*")*<(?:[\04
0\t]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff]|\((?:[^\\\x80-\xff\n\015()]
|\\[^\x80-\xff])*\))*\))*(?:@(?:[\040\t]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x
80-\xff]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff])*\))*\))*(?:[^(\040)<>@
,;:".\\\[\]\000-\037\x80-\xff]+(?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]
)|\[(?:[^\\\x80-\xff\n\015\[\]]|\\[^\x80-\xff])*\])(?:(?:[\040\t]|\((?:[^\\
\x80-\xff\n\015()]|\\[^\x80-\xff]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff
])*\))*\))*\.(?:[\040\t]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff]|\((?:[^
\\\x80-\xff\n\015()]|\\[^\x80-\xff])*\))*\))*(?:[^(\040)<>@,;:".\\\[\]\000-
\037\x80-\xff]+(?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff])|\[(?:[^\\\x80-
\xff\n\015\[\]]|\\[^\x80-\xff])*\]))*(?:(?:[\040\t]|\((?:[^\\\x80-\xff\n\01
5()]|\\[^\x80-\xff]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff])*\))*\))*,(?
:[\040\t]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff]|\((?:[^\\\x80-\xff\n\0
15()]|\\[^\x80-\xff])*\))*\))*@(?:[\040\t]|\((?:[^\\\x80-\xff\n\015()]|\\[^
\x80-\xff]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff])*\))*\))*(?:[^(\040)<
>@,;:".\\\[\]\000-\037\x80-\xff]+(?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xf
f])|\[(?:[^\\\x80-\xff\n\015\[\]]|\\[^\x80-\xff])*\])(?:(?:[\040\t]|\((?:[^
\\\x80-\xff\n\015()]|\\[^\x80-\xff]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\x
ff])*\))*\))*\.(?:[\040\t]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff]|\((?:
[^\\\x80-\xff\n\015()]|\\[^\x80-\xff])*\))*\))*(?:[^(\040)<>@,;:".\\\[\]\00
0-\037\x80-\xff]+(?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff])|\[(?:[^\\\x8
0-\xff\n\015\[\]]|\\[^\x80-\xff])*\]))*)*:(?:[\040\t]|\((?:[^\\\x80-\xff\n\
015()]|\\[^\x80-\xff]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff])*\))*\))*)
?(?:[^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+(?![^(\040)<>@,;:".\\\[\]\000
-\037\x80-\xff])|"(?:[^\\\x80-\xff\n\015"]|\\[^\x80-\xff])*")(?:(?:[\040\t]
|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff]|\((?:[^\\\x80-\xff\n\015()]|\\[
^\x80-\xff])*\))*\))*\.(?:[\040\t]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xf
f]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff])*\))*\))*(?:[^(\040)<>@,;:".\
\\[\]\000-\037\x80-\xff]+(?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff])|"(?:
[^\\\x80-\xff\n\015"]|\\[^\x80-\xff])*"))*(?:[\040\t]|\((?:[^\\\x80-\xff\n\
015()]|\\[^\x80-\xff]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff])*\))*\))*@
(?:[\040\t]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff]|\((?:[^\\\x80-\xff\n
\015()]|\\[^\x80-\xff])*\))*\))*(?:[^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff
]+(?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff])|\[(?:[^\\\x80-\xff\n\015\[\
]]|\\[^\x80-\xff])*\])(?:(?:[\040\t]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\
xff]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff])*\))*\))*\.(?:[\040\t]|\((?
:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80
-\xff])*\))*\))*(?:[^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+(?![^(\040)<>@
,;:".\\\[\]\000-\037\x80-\xff])|\[(?:[^\\\x80-\xff\n\015\[\]]|\\[^\x80-\xff
])*\]))*(?:[\040\t]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff]|\((?:[^\\\x8
0-\xff\n\015()]|\\[^\x80-\xff])*\))*\))*>)(?:[\040\t]|\((?:[^\\\x80-\xff\n\
015()]|\\[^\x80-\xff]|\((?:[^\\\x80-\xff\n\015()]|\\[^\x80-\xff])*\))*\))*


>From ASkwar@DigitalProjects.com Date: Tue,  9 Oct 2001 21:22:36 +0200
Return-Path: <ASkwar@DigitalProjects.com>
Mailing-List: contact imp-help@lists.horde.org; run by ezmlm
Delivered-To: mailing list imp@lists.horde.org
Received: (qmail 30491 invoked from network); 9 Oct 2001 19:56:19 -0000
Received: from mailout06.sul.t-online.com (HELO mailout06.sul.t-online.de) (194.25.134.19)
  by clark.horde.org with SMTP; 9 Oct 2001 19:56:19 -0000
Received: from fwd02.sul.t-online.de 
	by mailout06.sul.t-online.de with smtp 
	id 15r2zC-0000A8-01; Tue, 09 Oct 2001 21:56:18 +0200
Received: from teich.garten.digitalprojects.com (510044997847-0001@[217.83.105.124]) by fmrl02.sul.t-online.com
	with esmtp id 15r2TX-2IeG0Wq; Tue, 9 Oct 2001 21:23:35 +0200
Received: by teich.garten.digitalprojects.com (Postfix, from userid 48)
	id 5103C78746; Tue,  9 Oct 2001 21:22:36 +0200 (CEST)
Received: from pd953697c.dip.t-dialin.net ( [pd953697c.dip.t-dialin.net])
	as user askwar@localhost by horde.imp.lieder.ath.cx with HTTP;
	Tue,  9 Oct 2001 21:22:36 +0200
Message-ID: <1002655356.3bc34e7c1f728@horde.imp.lieder.ath.cx>
Date: Tue,  9 Oct 2001 21:22:36 +0200
From: Alexander Skwar <ASkwar@DigitalProjects.com>
To: imp@lists.horde.org
References: <1002404743.3bbf7b87f16ae@horde.imp.lieder.ath.cx> <1002418587.3bbfb19b79b18@horde.imp.lieder.ath.cx> <20011007111720.A18894@teich.Garten.DigitalProjects.com> <1002637612.3bc3092cd84f9@marina.horde.org> <1002646254.3bc32aeeea0fe@horde.imp.lieder.ath.cx> <1002650749.3bc33c7dbd71d@marina.horde.org> <20011009144206.C20122@csh.rit.edu>
In-Reply-To: <20011009144206.C20122@csh.rit.edu>
MIME-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-15
Content-Transfer-Encoding: 8bit
User-Agent: Internet Messaging Program (IMP) 2.3.7-cvs
X-Originating-IP: 217.83.105.124
X-Sender: 510044997847-0001@t-dialin.net
Subject: Re: [imp] Mails aren't wrapped

Zitat von Jon Parise <jon@horde.org>:

> On Tue, Oct 09, 2001 at 02:05:49PM -0400, Chuck Hagenbuch wrote:
> 
> > If you feel strongly, go ahead and commit it, Jon.
> 
> At the risk of sounding incredibly stupid ...
> 
> I confused the two screenshots.  I like things the way they are
> now.

:(((  It looks like a mess the way it is now.  Compare these screenshots
below.  This shows, that it is not only looking better in Mozilla, but
also in Opera and Netscape 4.78.

Messie in Mozilla:
http://dp.ath.cx/~askwar/Shot/2001_10_09_211423_shot.png

Nice in Mozilla:
http://dp.ath.cx/~askwar/Shot/2001_10_09_211445_shot.png

Messie in Opera:
http://dp.ath.cx/~askwar/Shot/2001_10_09_211144_shot.png

Nice in Opera:
http://dp.ath.cx/~askwar/Shot/2001_10_09_211156_shot.png

Messie in Netscape 4.78:
http://dp.ath.cx/~askwar/Shot/2001_10_09_211837_shot.png

Nice in Netscape 4.78:
http://dp.ath.cx/~askwar/Shot/2001_10_09_211942_shot.png

Now, in Netscape 4.78 you've got to scroll anyway, so it might as well
look orderly.

How does it look like in the devils browser?  Thanks god, I don't have
it at my hands, so I can't tell...

Alexander Skwar
-- 
How to quote:  http://learn.to/quote (de) http://quote.6x.to (en)
Homepage:      http://www.digitalprojects.com | http://www.iso-top.de
   iso-top.de - Die günstige Art an Linux Distributionen zu kommen

-------------------------------------------------
This mail sent through IMP: http://horde.org/imp/