PHP Classes

Custom headers

Recommend this page to a friend!

      MIME E-mail message sending  >  MIME E-mail message sending package blog  >  How Can PHP Send Emai...  >  All threads  >  Custom headers  >  (Un) Subscribe thread alerts  
Subject:Custom headers
Summary:Custom headers with MIME Email
Messages:4
Author:BANJAC
Date:2008-04-22 20:42:57
Update:2008-04-24 10:01:14
 

  1. Custom headers   Reply   Report abuse  
Picture of BANJAC BANJAC - 2008-04-22 20:42:57
We re looking for an esay way to track back our email sent.

Is it possible to add custom headers (Like X-Myheader:emailID-2344) with the MIME Email Class.

And how to make sure that information will be kept if the email sent is fowarded. It seems some parts of the previous header dispeared when it s no standard.

Thanks for your advice.

Dimitri

  2. Re: Custom headers   Reply   Report abuse  
Picture of Manuel Lemos Manuel Lemos - 2008-04-23 00:19:28 - In reply to message 1 from BANJAC
You can set any header you want with SetHeader function.

When a message is forwarded by a mail server, usually all message headers are preserved.

  3. Re: Custom headers   Reply   Report abuse  
Picture of BANJAC BANJAC - 2008-04-24 09:39:52 - In reply to message 2 from Manuel Lemos
Thanks Manuel.

I'm taking the chance of this reply to congrat you for all of this wonderfull work you did and you have shared to the communauty. Thanks very much for that.

To conlude this post, I wanted to be sure to have well understood. How does Gmail or Yahoo, to retrieve the thread of a discussion and present it in a logicla way in their email interface. I guess they use a custom parameter that they retrieve if the email is back (as fowarded or replied).

What advice would you give us to permit a tracking of our email sent with your class: use the Reference header, X-perso header, or else strategy ?

It seems that most of our customs headers disapear in case of fowarding. A new Email header is set by the server. Shoud we have to do something to say the server to keep this information?

Hoping you could help. Thanks again anyway.

Best regards

Dimitri

  4. Re: Custom headers   Reply   Report abuse  
Picture of Manuel Lemos Manuel Lemos - 2008-04-24 10:01:14 - In reply to message 3 from BANJAC
Thanks.

Usually the References header contain a list of values that are the Message-ID header values of all messages that belong to the same thread.

It all depends on how you forward the message. You can forward a message setting all headers that you got. You can also replay and forward the original message as an attachment. It depends on why you are forwarding a message.