Reply to Re: Can't get \n to work.

Your name:

Reply:


Posted by Colin Fine on 10/06/06 16:36

sk wrote:
> According to zend.com
>
> Double and single quoted strings are handled differently by PHP. Double
> quoted strings are interpreted while single quoted strings are treated
> exactly as written. For example:
>
> $foo = 2;
> echo "foo is $foo"; // this prints: foo is 2
> echo 'foo is $foo'; // this prints: foo is $foo
> echo "foo is $foo\n"; // this prints: foo is 2 (with a new-line)
> echo 'foo is $foo\n'; // this prints: foo is $foo\n
>
> I can not get this to work.
>

And we're all supposed to guess in what way it doesn't work?

I'm sorry if this sounds crabby, sk, but it is a bugbear of mine at work
as well as here.

'I can't get this to work' is as much use as 'My car won't go'.

PLEASE, if you ask for assistance, give people the information they need
to render assistance: tell them
- what you did
- what happened (including what you saw)
- what system/context you were in
- what you expected, if it is not obvious.

</lecture>

Colin

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация