Quantcast
Channel: Active questions tagged email - Stack Overflow
Viewing all articles
Browse latest Browse all 29748

Send PHP mails so mails stack as one conversation in inbox

$
0
0

I have a chat system were notifications about the chat are send to the emailadreses which are involved. I would like to imitate the effect of conversation stacking in the receiver's inbox. Is there a way to do this?

I tried:

$headers = [
    'Thread-Topic' => $subject
];
wp_mail( 'test@test.com', $subject, $content, $headers);

and

wp_mail( 'test@test.com', 'RE: '.$data['onderwerp'], $content );

and

$headers = [
    'Message-ID' => 'custommailsystem'
];
wp_mail( 'test@test.com', $subject, $content, $headers);

Sending emails works, but they do not stack as one conversation in the receiver's inbox. They show up as separate mails, like this:

unstacked emails

To make sure the receiver gets the emails in a organised way, I want emails to stack like this in the receiver's inbox:

stacked emails by conversation

Which headers are used to achieve the stacking in the mail? What determines in which conversation an email belongs?


Viewing all articles
Browse latest Browse all 29748

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>