PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
Moderator: General Moderators
mjseaden
Forum Contributor
Posts: 458 Joined: Wed Mar 17, 2004 5:49 am
Post
by mjseaden » Tue May 18, 2004 4:00 am
Dear All,
I am trying to write an e-mail message, using the symbol '\n' to signify new line. However, when I come to send the e-mail message, '\n' actually appears in the e-mail text. How do I create a new line when writing e-mail text?
Many thanks
Mark
feyd
Neighborhood Spidermoddy
Posts: 31559 Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA
Post
by feyd » Tue May 18, 2004 4:12 am
try "\n"
mjseaden
Forum Contributor
Posts: 458 Joined: Wed Mar 17, 2004 5:49 am
Post
by mjseaden » Tue May 18, 2004 4:14 am
Hi Feyd,
Do you mean I should use double quotes " instead of single quotes ' ?
JayBird
Admin
Posts: 4524 Joined: Wed Aug 13, 2003 7:02 am
Location: York, UK
Contact:
Post
by JayBird » Tue May 18, 2004 4:19 am
Show your code
I don't think Feyd read your message to be honest, just answered the topic title!?!
Mark
feyd
Neighborhood Spidermoddy
Posts: 31559 Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA
Post
by feyd » Tue May 18, 2004 4:27 am
no I read it. I meant double quotes.. I've had a few times where that or how I was using it was screwing up.
patrikG
DevNet Master
Posts: 4235 Joined: Thu Aug 15, 2002 5:53 am
Location: Sussex, UK
Post
by patrikG » Tue May 18, 2004 5:33 am
The difference between single- and double-quotes is that PHP parses anything between double-quotes.
Code: Select all
<?php
$var = "hello";
echo '$var';
//will output: $var
echo "$var";
//will output: hello
?>