SEND MAIL: "Cannot modify header information" error
Hello,
Debug mode is on for a "contact us" box on a Contact Page.
This is now producing the error:
Cannot modify header information - headers already sent by (output started at /var/www/vhosts/nav ... .com/httpdocs/webassist/email/phpmailer/src/SMTP.php:277) in /var/www/vhosts/nav ... .com/httpdocs/webassist/email/WA_Email.php on line 412
I have left debug mode on for you to test at the location given in the private area in the next screen.
But the errors seem to be generated by:
case 'html':
//Cleans up output a bit for a better looking, HTML-safe output
echo gmdate('Y-m-d H:i:s'), ' ', htmlentities(
preg_replace('/[\r\n]+/', '', $str),
ENT_QUOTES,
'UTF-8'
), "<br>\n";
break;
AND :
public function redirect() {
if ($this->Redirect) {
header("location: " . $this->Redirect);
die();
}
}
This is of course preventing the appearance of the contact_success.php page.
Thank you.