Solved

Removing quoted text from an email

Posted on 2011-03-01
4
1,112 Views
Last Modified: 2012-05-11
I'm parsing an email and I was able to extract the 'text/plain' and 'text/html' contents of the mail. My problem now is that I can't extract the 'actual text' from the the whole text (with q'uoted text'). Here's an example.

this is a reply

On Tue, Mar 1, 2011 at 6:32 PM, Jan Michael Chuaquico <
jmschuaquico@gmail.com> wrote:

> test
>
(gmail example)

I only want the 'this is a reply' and not the 'test'. This may be easy if all the emails have this format. But it varies depending on the email client. Here's an example from Yahoo!

test2




________________________________
From: Jewel Garcia
To: Jehaziel Jeiel Garcia
Sent: Tuesday, March 1, 2011 7:48:42 PM
Subject: subject


test

How am I going to solve this problem? Maybe you guys know of any existing classes that has solved this already? Thanks!
0
Comment
Question by:rationalboss
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 7

Expert Comment

by:Vimal DM
ID: 35008877
Hai,

"PHPMAILER" is the best one to process the mailing

1) Can send bulk mails
2) Can have bulk attachment
3) Can avoid spams,and the problems that you face on each different mail id's
4) Any type of mail id's will be accepted to the mailer class


just a single mailer class,and code that you know to use

it is available on net

Very Good Code
0
 
LVL 110

Expert Comment

by:Ray Paseur
ID: 35011641
I'm guessing that you're referring to parsing the email in a PIPE script, right?  I have never seen any class that can do what you're describing here.  I think you are on the path of original research.  Unfortunately there are almost as many formats for forwarded and replied-to messages as there are email reader programs.

If you want to post the complete original messages with the headers for a few samples, I will be glad to look at them and try to make some generalized solutions.
0
 
LVL 8

Accepted Solution

by:
rationalboss earned 0 total points
ID: 35052352
0
 
LVL 8

Author Closing Comment

by:rationalboss
ID: 35107001
No solution was provided so I just made a more extensive Google search.
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Author Note: Since this E-E article was originally written, years ago, formal testing has come into common use in the world of PHP.  PHPUnit (http://en.wikipedia.org/wiki/PHPUnit) and similar technologies have enjoyed wide adoption, making it possib…
This article discusses how to implement server side field validation and display customized error messages to the client.
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.

691 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question