Forum Moderators: coopster
I want to know how to make the call from the html code that will be in the email message to the script, and how to properly terminate the script so that it displays a spacer gif.
It looks like I need to include in the email message something like this:
<img src="http://example.com/script.php?email="blah@blah.com"&client="client_name" />
But, once I get the parameters in the script, how do I properly display a tracking pixel, or otherwise terminate the script so that the rest of the HTML message gets displayed?
The messages need to be created in a form box on the fly, so I will need to include this tracking code in the PHP script that sends the email.
- Joe
- Joe
Why?
Simply because most e-mail clients (Outlook, Thunderbird) block remote requests, including images, by default. In short, there's no simple, reliable way of determining whether someone has opened an e-mail or not.
However, if you can convince users to allow remote images within the message, all you really need to do is have a 1px image on your server, call it with include() (or, to be more secure, possibly use file_get_contents() and echo), then exit the script without producing any output.