How to do email read notification in PHP

How to do email read notification in PHP

Dec 9th, 2005 02:04
Morne Roets, Rupak Dum,

Well there are a few ways.
But the main problem is that these day’s withall the spam filters it’s not easy to do tracking anymore.
And you don’twant to be added to the “spam” list on all the mail servers by onlydoing “read tracking report”.

The method i use “WEB BEACON” is relative safe and “almost”undetectable.
The only problem is that the person that reads the emailmust be able to view images in the HTML email or
click on the “downloadimage” link in Outlook 2000 and above.

What we do is we create an HTML email and add this “image tag” anywhereon the Email.

//=========== In the html email ======
<imgsrc=”http://www.youserver.com/newsletter_report.php?email=emailofuser “border=”0″ width=”150″ height=”40″>
//=========== End Email ==============

Most people just use a blank 1×1 pix image but i’ve used my companys’logo as my “web bugs” or “WEB BEACON”.

This means that when the user click on “download all images” Outlookwill request the newsletter_report.php
script waiting for a image response.

The next part is actually easy …

//============= In your newsletter_report.php script ==============

function sendGIF(){

// open the file in a binary mode
$name = “sentBy8.png”;

//Open and read in binary
$fp = fopen($name, ‘rb’);

// send the right headers
header(“Content-Type: image/gif”);
header(“Content-Length: ” . filesize($name));

// dump the picture and stop the script
fpassthru($fp);
}

// Make sure image is sent to the browser immediately
ob_implicit_flush(TRUE);

// keep running after browser closes connection
@ignore_user_abort(true);

sendGIF();

// Browser is now gone…

// Switch off implicit flush again – we don’t want to send any more output
ob_implicit_flush(FALSE);

// Catch any possible output (e.g. errors)// – probably not needed but better safe…
ob_start();

//Start your processing here…

// ============== Ens script ==================================

When outlook request the newsletter_report.php script we send an imageback on do tracking on
the $_REQUEST vars passed from the link in the email.

You can even take this script to the next level and do tracking for howlong the email
was opened etc … :-)

Just remember that this type of tracking is often know as spyware. Butyou can just notify
your newsletter clients that you do open ratetracking for advertising purposes. (In the small
print)

Hope this helps, i’ve researched all possible tracking options, but thisis the best by far.Tip:
make your HTML Email with a lot of images to “force” the reader todownload all the offside images.

Deixe uma resposta

Preencha os seus dados abaixo ou clique em um ícone para log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Sair / Alterar )

Imagem do Twitter

You are commenting using your Twitter account. Sair / Alterar )

Foto do Facebook

You are commenting using your Facebook account. Sair / Alterar )

Connecting to %s


Seguir

Obtenha todo post novo entregue na sua caixa de entrada.