[prev in list] [next in list] [prev in thread] [next in thread]
List: kmail-devel
Subject: Email address matching in KMReaderWin::strToHtml()
From: Dave Corrie <kde () davecorrie ! com>
Date: 2002-04-19 14:32:17
[Download RAW message or body]
Hi,
I'm currently working on the code in KMReaderWin::strToHtml() and
noticed something odd about the way it turns email addresses into
hyperlinks.
Basically, it looks for a '@' character and then scans backwards and
forwards for the rest of the address. The odd thing is that it
terminates after scanning 255 chars, which has the following effect:
('X' represents a sequence of 250 characters)
1) spamX@kde.org is not turned into a hyperlink
2) spam@Xkde.org is turned into
<a href="mailto:spam@X">spam@X</a>kde.org
IMO, both of these cases should either be turned into hyperlinks or they
should both be left as plain text (case (2) is definitely not very
useful at the moment). Would it be worth me modifying the way the
algorithm handles very long addresses? Should I:
a) Not turn addresses over 255 characters in length into hyperlinks
(i.e. leave them as plain text)?
b) Remove the limit of scanning only 255 characters, so that both the
above cases are turned into hyperlinks?
I had a look at RFC 2822 to see if there was a limit on the length of
valid email addresses, but I couldn't see anything relevant. Did I miss
something?
Thanks in advance,
Dave
_______________________________________________
KMail Developers mailing list
kmail@mail.kde.org
http://mail.kde.org/mailman/listinfo/kmail
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic