Log in

View Full Version : I'm sure this is simple but... (I'm new)



Junk Uno
04-15-2007, 01:23 AM
Want to send e-mails to our members that our usually a single graphic file.
All we want to do is have the graphic open once the e-mail is opened. The only way I've been showed to do it makes the user click the link to see the image, which besides being primitive, is fairly annoying. Is this easy to accomplish? Seems like it would be but I'm stuck.
I appreciate the help!!!

thetestingsite
04-15-2007, 01:36 AM
Are you using any server side languages (such as PHP, ASP, etc)? If you are using PHP, probably the best way I can think of doing this would be by sending an email in HTML format. The following example is taken from the PHP.net (http://php.net/function.mail) website:



<?php
// multiple recipients
$to = 'user@example.com'

// subject
$subject = 'Image from our website';

// message
$message = '
<html>
<head>
<title>Image from our website</title>
</head>
<body>
<img src="image.jpg">
</body>
</html>
';

// To send HTML mail, the Content-type header must be set
$headers = 'MIME-Version: 1.0' . "\r\n";
$headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";

// Additional headers
$headers .= 'From: PHP script <noreply@example.com>';

// Mail it
mail($to, $subject, $message, $headers);
?>


Hope this helps.