Solved

Email Tracking

Posted on 2011-09-14
15
264 Views
Last Modified: 2012-05-12
How can i track emails. I am sending newsletter emails from my system, i want to know who opened them. How can I track that.

I know it can be tracked if they click on display images, but can it be done even if they don't click "display images"

I am using PHP
0
Comment
Question by:nandananushil1
  • 6
  • 3
  • 3
  • +3
15 Comments
 
LVL 9

Expert Comment

by:oheil
ID: 36534527
You can do this by sending emails in HTML format. You could embed some unvisible graphics which must be downloaded from a server where you can analyse the download log files.
Tracking like this is typically regarded as bad behaviour, or just in my opinion.

Oli
0
 
LVL 21

Expert Comment

by:Papertrip
ID: 36534530
The only way to truly track the opening of emails is via a click-through.  You could add a header to request disposition of the mail (like requesting receipts in Outlook), but that is far from a guaranteed method to achieve what you want.
0
 
LVL 7

Expert Comment

by:boon86
ID: 36534564
You want to include some javascript on email content so you can track their hits.
you whip up some ajaxy code to do that:

var xmlhttp;
if (window.XMLHttpRequest)
  {// code for IE7+, Firefox, Chrome, Opera, Safari
  xmlhttp=new XMLHttpRequest();
  }
else
  {// code for IE6, IE5
  xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
  }
xmlhttp.onreadystatechange=function()
  {
  }
xmlhttp.open("POST","http://example.com/pixel.php",true);
xmlhttp.setRequestHeader("Content-type","application/x-www-form-urlencoded");
var url=escape(location.href);
var uid=1234;
var referrer=escape(document.referrer);
xmlhttp.send("url="+currenturl+"&referrer="+referrer+"&userid="+uid);

Open in new window


but it doesn’t work because you’re trying to do a cross-site ajax post.
what to do? pass info to a script posing as an image!

var url=escape(location.href);
var referrer=escape(document.referrer);
var pixel = new Image();
pixel.src = 'http://example.com/pixel.php'+ '?' + "url="+currenturl+"&referrer="+referrer+"&userid="+uid;

Open in new window


usage, simply include these 2 line into your html email content:
<script type="text/javascript">var uid=4321;</script>
<script type="text/javascript" src="http://example.com/pixel.js"></script>

Open in new window


hope that help
0
 
LVL 21

Expert Comment

by:Papertrip
ID: 36534583
@boon86 -- will that circumvent clients that don't download images or other potentially malicious content?
0
 
LVL 36

Expert Comment

by:Loganathan Natarajan
ID: 36534874
Using PHP , check out this
0
 
LVL 37

Accepted Solution

by:
Neil Russell earned 500 total points
ID: 36535042
Simply answer is you can't.

Almost ALL email systems now will block malicious content, even if it gets through their AV/AS filter system.  There is NO Gauranteed method to do this.

The ONLY way you could track is to publish the email content online and send each user a LINK to the webpage that they need to visit to read the content, with of course a login so you can record who has visited and read the content.
0
 
LVL 21

Expert Comment

by:Papertrip
ID: 36535054
Simply answer is you can't.

Almost ALL email systems now will block malicious content, even if it gets through their AV/AS filter system.  There is NO Gauranteed method to do this.

The ONLY way you could track is to publish the email content online and send each user a LINK to the webpage that they need to visit to read the content, with of course a login so you can record who has visited and read the content.

Oh, you mean what I already posted? :o

BTW it doesn't need a login, just an identifiable token in the URL.

And yes, there is a guaranteed method, a click-through.
0
How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

 
LVL 9

Expert Comment

by:oheil
ID: 36535087
Neilsr is right, you cannot track while sending all information inside the mail but with a client who refuses to be tracked (like me).

Oli
0
 
LVL 21

Expert Comment

by:Papertrip
ID: 36535094
Are my replies to this question not being seen or something?
0
 
LVL 9

Expert Comment

by:oheil
ID: 36535105
Sorry Patertrip, I did not see your last one, you are also right.
Currently I have only the basic skin which does not reload comments on the fly. I need to reload to the see the latest comment.
Oli
PS: sorry this is off topic, back to the question.


0
 
LVL 21

Expert Comment

by:Papertrip
ID: 36535117
Understood oheil, thank you for the clarification.  I try my best to not attack other Experts, but it drives me crazy when they post the same answer I do (on purpose)!!!  Seems to happen at least once a day, and it seems to have already happened once on this thread :-/

Apologies if my reply offended you, I appreciate your response.

0
 
LVL 37

Expert Comment

by:Neil Russell
ID: 36535288
I actually find your reply offensive. Nobody has Posted the same answer as you and definately not on purpose.
All you posted was was to say you can do with a click-through.
No explination or comment.

My comment explained to a user of unknown skill level how to go about doing something what he had asked how to do and explain why other methods may not always work.

There is a lot of difference between posting the same content or pasting the same link that somebody has already done, and yes, that is very annoying, and posting an explination of something that may be more meeningful to the questioner.

Kind Regards,

Neil
0
 
LVL 21

Expert Comment

by:Papertrip
ID: 36535431
@Neilsr/oheil,

I shouldn't have posted that reply in this thread.  I am new to EE, just over a week, and am now realizing there are different levels to what I perceived as duplicate answering.  Some are just plain blatant, and I got shafted on the solution a few times and was left pretty much with wtf.  What you said wasn't that, it was what I had said but explained in a different manner.  I can see the difference now between the two.

I'll just excuse myself from this thread.  Good luck nandananushil1.

0
 
LVL 37

Expert Comment

by:Neil Russell
ID: 36535445
No problems at all papertrip and welcome to EE :)
0
 
LVL 108

Expert Comment

by:Ray Paseur
ID: 36536627
I am sending newsletter emails from my system, i want to know who opened them. How can I track that.

Here is my advice, based on many years of sending emails from my systems.  I send several thousand a month.  If there is any economic value to your email messages, Give up, and stop sending your own emails!

Instead, engage the services of this company.  They already do everything you need and their services are embarrassingly inexpensive.
http://www.constantcontact.com/index.jsp

There are competitor services, of course, but in my experience Constant Contact is the most professional.  There are many layers of experience that underpin my recommendation, most notably the enormous amount of time that I have spent in non-value-added activities that attend to the way the email system works or does not work.  For literally pennies, you can get the services of a firm that has many full-time employees dedicated to the task of making sure your email messages look good, reach the intended recipients, get tracked and reported, etc.
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
spacing 5 27
How can I assign SimpleXMLElements to variables? 5 29
Not needed 13 54
Return data with AJAX, JQUERY and PHP 13 27
Follow this checklist to learn more about the 15 things you should never include in an email signature from personal quotes, animated gifs and out-of-date marketing content.
Since pre-biblical times, humans have sought ways to keep secrets, and share the secrets selectively.  This article explores the ways PHP can be used to hide and encrypt information.
Learn how to match and substitute tagged data using PHP regular expressions. Demonstrated on Windows 7, but also applies to other operating systems. Demonstrated technique applies to PHP (all versions) and Firefox, but very similar techniques will w…
This video shows how to remove a single email address from the Outlook 2010 Auto Suggestion memory. NOTE: For Outlook 2016 and 2013 perform the exact same steps. Open a new email: Click the New email button in Outlook. Start typing the address: …

707 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

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now