Re: Mail conversation parser?
| From: | Jan Schneider | Date: | Tue, 21 Sep 2004 09:29:47 +0000 |
| Subject: | Re: Mail conversation parser? | ||
| References: | 1 2 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-33505@lists.php.net to get a copy of this message | ||
Zitat von Richard York <richy@smilingsouls.net>:
Turadg Aleahmad wrote:You might want to take a look at Horde's Text package at http://cvs.horde.org/framework/Text that provides most of these features.Hi, folks. My site has a mail gateway for our custom forums. It was written years ago and I've been converting some of the code to use PEAR classes that are now available: Mail, Mail_mime, Mail_RFC822, etc. One feature of our forums that I haven't found a PEAR class for is parsing out the novel content of an e-mail reply à la Gmail. When a user replies by e-mail to a comment they received, their mail app automatically tacks on some "Some Dude wrote:" and a quote of all that. Since we're posting the message within a threaded web forum, that part is redundant. Is anyone working on functionality like this for PEAR? Mail_Conversations or somesuch? If not, is anyone interested in such functionality if I where to contribute it? If so, where should it go?I was thinking about writing such a package, but haven't yet been able to get around to it. Such a package should have, IMO,
* Parsing and replacement of urls with clickable links in plain text messages.Text::linkUrls() or Text_Filter_linkurls
* Perhaps some other formating options for plain text.Text::highlightQuotes()i.e. convert dashed lines to horizontal rules,
Text::toHTML() or Text_Filter_bbcodeparse and replace forum code (via HTML_BBCodeParser of course).
Text::dimSignature()grayed out text below the double dash '-- '.
* Regex to find and replace CIDs with file paths for multipart/relatedText::linkMailtos() or Text_Filter_emailsmessages* Replacement of mailto: links in Plain text/HTML message, so thatone could install a click link to their own message composer app.
* Conversations.Text_Flowed (RFC 2646) Any help to polish these classes/package up is welcome. Jan. -- Do you need professional PHP or Horde consulting? http://horde.org/consulting/