Вот как выглядит мой PHP-код
Код: Выделить всё
$email_message = '
.container { font-family: Arial, sans-serif; }
.header { background-color: #f4f4f4; padding: 20px; }
.content { padding: 20px; }
.button {
color: #fff;
background: #009688;
border-radius: 6px;
padding: 0;
}
#companyName {
color: #009688;
}
Welcome to Company Name
Hi' . $first_name . ',
Thank you for signing up. We're excited to have you on board!
[url=https://mycompany.com/login]Click here to login[/url]
Best regards,
The Team
';
// From is required - update with your sender
$headers = 'From: ' . "\r\n";
// The content type is required when sending HTML Based emails.
$headers = "Content-type:text/html;charset=UTF-8" . "\r\n";
$headers = "MIME-Version: 1.0" . "\r\n";
// calling the mail function to send the mail using the hosted web server.
mail($to,$subject,$email_message,$headers);
Код: Выделить всё
.container { font-family: Arial, sans-serif; }
.header { background-color: #f4f4f4; padding: 20px; }
.content { padding: 20px; }
.button {
color: #fff;
background: #009688;
border-radius: 6px;
padding: 0;
}
#companyName {
color: #009688;
}
Welcome to Company Name
Hi Bob,
Thank you for signing up. We're excited to have you on board!
[url=https://mycompany.com/login]Click here to login[/url]
Best regards,
The Team
Подробнее здесь: https://stackoverflow.com/questions/798 ... ted-string
Мобильная версия