Php email
Moderator: General Moderators
Re: Php email
If you only have a couple of words in your content, or a one worder like "test" as your subject it may show up as SPAM. Check that isn't the case first
Re: Php email
still posted in junk
Re: Php email
Maybe fill out necessary headers, something like this:
Then pass it through. Are you using PHPMailer or are you just using the mail() function?
Code: Select all
$headers = "From: \"".$from_name."\" <".$from_email.">\n";
$headers .= "To: \"".$to_name."\" <".$to_email.">\n";
$headers .= "Return-Path: <".$from_email.">\n";
$headers .= "MIME-Version: 1.0\n";
$headers .= "Content-Type: text/HTML; charset=ISO-8859-1\n";
Re: Php email
Code: Select all
$result = mysql_query($query) or die(mysql_error());
while($row = mysql_fetch_array($result)){
$to = $row['email'];
$subject = 'Szeryk Newsletter - Vol: \r\n' . $vol;
$headers = "From: noreply@szeryk.com\r\n";
$headers .= "MIME-Version: 1.0\r\n";
$headers .= "Content-Type: text/html; charset=ISO-8859-1\r\n";
$message = "<html>Re: Php email
One question, why do you set the headers within the while loop, you are redefining the variables each time. Not that it has anything to do with it.
Try this link: http://www.transio.com/content/how-pass ... s-php-mail
Try this link: http://www.transio.com/content/how-pass ... s-php-mail