MDanz Posted November 10, 2009 Share Posted November 10, 2009 $to = $email; $subject = "Activate your account!"; $headers = "From: [email protected]"; $server = "http://www.default.com"; ini_set("SMTP",$server); $body=" Hello $fullname, \n\n You need to activate your account to participate in stackway. Follow the link below: http://www.default.com/activate.php?id=$lastid&code=$random\n\n \n\n "; this is the email that is sent to people that register. How do i include an image? I tried image source, but it doesn't work, when i check my email. I want the logo for my site in this email. any ideas? Link to comment https://forums.phpfreaks.com/topic/180936-help-including-image-in-email/ Share on other sites More sharing options...
kevin_newbie Posted November 10, 2009 Share Posted November 10, 2009 When you tried image source did you use absolute link instead of relative link? So when you display image it should go along the lines of <img src="http://yourdomain.com/image/to/path" width="" height="" alt="" /> Then it should work. Along with having the header stating that there is html and image file in the email. http://php.net/manual/en/function.mail.php That page should help you as far as what headers you need in this case. Hopes that helps you out. Link to comment https://forums.phpfreaks.com/topic/180936-help-including-image-in-email/#findComment-954556 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.