Doubts on "headers"!!

Swift Mailer is a fantastic library for sending email with php. Discuss this library or ask any questions about it here.

Moderators: Chris Corbyn, General Moderators

Post Reply
guma
Forum Newbie
Posts: 2
Joined: Mon Jan 21, 2008 5:29 pm

Doubts on "headers"!!

Post by guma »

Next my mail server requires a pradrao differently than it has in the library SWIFTS.


Padrao required is this:

Code: Select all

$headers  = "MIME-Version: 1.0\r\n";
$headers .= "Content-type: text/html; charset=iso-8859-1\r\n";
$headers .= "From: ".$fromName." <".$from.">\r\n";
I wonder how I put it in my default code?

So I know that there is more outside that I lost someone can give me a hand?

$message =& new Swift_Message($assunto, $texto, "text/html");


I await in the
User avatar
Chris Corbyn
Breakbeat Nuttzer
Posts: 13098
Joined: Wed Mar 24, 2004 7:57 am
Location: Melbourne, Australia

Re: Doubts on "headers"!!

Post by Chris Corbyn »

Swift Mailer already includes those headers. If you need to specify the iso-8859-1 part, then do this:

Code: Select all

$message =& new Swift_Message($assunto, $texto, "text/html", "iso-8859-1");
guma
Forum Newbie
Posts: 2
Joined: Mon Jan 21, 2008 5:29 pm

Re: Doubts on "headers"!!

Post by guma »

Chris Corbyn wrote:Swift Mailer already includes those headers. If you need to specify the iso-8859-1 part, then do this:

Code: Select all

$message =& new Swift_Message($assunto, $texto, "text/html", "iso-8859-1");

Earned face

It worked
Post Reply