http://www.php.net/manual/en/language.types.string.php

Just the way ' and " are defined. " understands more escape sequences then
'.

Justin Garrett


"Duncan" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Hi,
>
> i am just adding some mail() functions to my script and had to realize,
> that this:
>
> $email_from = 'From: [EMAIL PROTECTED]\r\nReply-To:
> [EMAIL PROTECTED]\r\n';
> mail($_POST['email'],'Your account details','You can login with your
> account details\r\nusername: '.$_POST['username'].'\npassword:
> '.$_POST['password'].'\n\nhere: http://----/index.php',$email_from);
>
> will make the email include the \r\n instead of adding a line feed, but
> this works just fine:
>
> $email_from = "From: [EMAIL PROTECTED]\r\nReply-To:
> [EMAIL PROTECTED]\r\n";
> mail($_POST['email'],'Your account details',"You can login with your
> account details\r\nusername: ".$_POST['username']."\npassword:
> ".$_POST['password']."\n\nhere: http://----/index.php",$email_from);
>
> Why is there this difference in the normal- & double-quoted string, i
> though it would only affect included variables, where one shows them and
> the other would need them to be added via '.' ?
>
> ...just curious :)
>
> Regards,
> Duncan
>



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to