Currently I'm making a system to track my emails, however I don't wish to have the original message displayed.
Is there a way to request IMAP to return only the reply? not the entire(when you press reply to an email from any email client, it adds the original email to the bottom). Or do it via PHP itself? I currently have
$msg = nl2br($msg);
$msgs2 = explode("<br />", $msg);
//pre($msgs2);
foreach($msgs2 as $msg) {
if(strpos($msg, '> ') === false) $message .= "<br>".$msg;
}
return $message;
However if you look at raw gmail reply, it has thing ssuch as HTML version etc..
> --f46d0442889037c1fc04b6c20955 Content-Type: text/plain; charset=ISO-8859-1
>
> fghjfghjfgh test test eteststs
>
> On Tue, Jan 17, 2012 at 11:35 PM, mm <
> mg.com> wrote:
>
> >
> > On 17 Jan 2012, at 05:56, mom wrote:
> >
> > > Another email hahahahqa!
> > > On 17 Jan 2012, at 05:47, mcom wrote:
> > >
> > >> Test message, higgins is very fat
> > >>
> > >>
> > >>
> > >>
> > >>
> > >> Please do not edit below
> > >> *************************
> > >> S
> > >
> >
> >
>
>
> --
>
> --f46d0442889037c1fc04b6c20955 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
>
> fghjfghjfgh test test eteststs<br><br><div class=3D"gmail_quote">On
> Tue, Ja= n 17, 2012 at 11:35 PM, <a
> href=3D"mailto:maom">mm</a>
> <span dir=3D"ltr"><<a href=3D"mailto:mn=
> g.com">ma</a>></span> wrote:<br> <blockquote
> class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1p= x
> #ccc solid;padding-left:1ex"><br> On 17 Jan 2012, at 05:56, <a href=3D"mailto:.com">mag.com</a>
> wrote:<br> <br> > Another email hahahahqa!<br> > On 17 Jan 2012,
> at 05:47, <a href=3D"mailto:.com">ma=
> na.com</a> wrote:<br> ><br> >> Test message,
> higgins is very fat<br> >><br> >><br> >><br>
> >><br> >><br> >> Please do not edit below<br>
> >> *************************<br> >> S<br> ><br> <br> </blockquote></div><br><br
> clear=3D"all"><div><br></div>-- <br>Regards,<div=
> >,</div><div>=A0</div><br>
>
> --f46d0442889037c1fc04b6c20955--
But thats just gmail, there are a lot of other email clients and so on, anyone could help?