On Wed, 2007-06-13 at 09:51 -0400, Daniel Brown wrote:
>
>     It's also not necessary to combine single and double quotes with
> join marks (.'s) as you have it.  While this isn't the problem, and
> Stut is absolutely correct, your code would look cleaner if you did it
> as follows:
> 
> <?
> $to = "[EMAIL PROTECTED]";
> 
> $subject = "Message Sent From Website";
> 
> $message  = "Hi!\n";
> $message .= "\tThis is also an example of how to use double quotes\n";
> $message .= "to encapsulate special characters such as the newline\n";
> $message .= "and tab characters.  If you need to escape \"quotes\" you\n";
> $message .= "simply backslash them like above.  Also, note that this\n";
> $message .= "message can be very long by using the dot before the\n";
> $message .= "equals sign.  Another way to do this would be to use\n";
> $message .= "HEREDOC syntax, or simply use one continuing line,\n";
> $message .= "but that's for another time and another example.\n";

$message  =
    "Hi!\n"
   ."\tThis is also an example of how to use double quotes\n"
   ."to encapsulate special characters such as the newline\n"
   ."and tab characters.  If you need to escape \"quotes\" you\n"
   ."simply backslash them like above.  Also, note that this\n"
   ."message can be very long by using the dot before the\n"
   ."equals sign.  Another way to do this would be to use\n"
   ."HEREDOC syntax, or simply use one continuing line,\n"
   ."but that's for another time and another example.\n";

:B

Cheers,
Rob.
-- 
.------------------------------------------------------------.
| InterJinn Application Framework - http://www.interjinn.com |
:------------------------------------------------------------:
| An application and templating framework for PHP. Boasting  |
| a powerful, scalable system for accessing system services  |
| such as forms, properties, sessions, and caches. InterJinn |
| also provides an extremely flexible architecture for       |
| creating re-usable components quickly and easily.          |
`------------------------------------------------------------'

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

Reply via email to