這裏是我的代碼: -電子郵件會在垃圾郵件中的蛋糕PHP
//Sending mail
if ($this->Session->read('Enrollment.personalinfo_language') == 'English') {
$language = "english";
$subject = "Thank you for submitting your enrollment request to Apna Energy.";
} else {
$language = "spanish";
$subject = "Gracias por enviar su solicitud de inscripci?n a Apna Energy.";
}
$details = $this->Session->read('Enrollment');
$details['plan_name'] = $product['Product']['name'];
$details['rate'] = $plan_rate;
$details['term'] = $product['Term']['term'];
$this->Email->sendAs = 'html';
$this->Email->from = 'Apna Energy <[email protected]>';
$this->Email->to = $this->Session->read('Enrollment.personalinfo_first_name') . ' ' . $this->Session->read('Enrollment.personalinfo_last_name') . '<' . $this->Session->read('Enrollment.personalinfo_email') . '>';
$this->Email->bcc = array('[email protected]');
$this->Email->subject = $subject;
$this->set('details', $details);
if ($this->Session->read('Enrollment.personalinfo_language') == 'English') {
$template = "enrollment_confirmation";
} else {
$template = "enrollment_confirmation";
}
$this->Email->template = $template;
$this->Email->send();
我的問題是,如果他們是在「到」接受他/她的垃圾郵件文件夾..客戶的郵件ID的郵件客戶填表..和我的郵件編號在「BCC」我的郵件來了罰款,我的收件箱文件夾..
我順着兩個URL,但他們並沒有爲我工作了..
How do you make sure email you send programmatically is not automatically marked as spam?
引導我在正確的方向.. 謝謝!!
請格式化您的問題以使其可讀。 –
我已經形成了清晰的代碼.. –