Re: Date Problem with \n

From: Date: Mon, 13 Aug 2007 17:55:05 +0000
Subject: Re: Date Problem with \n
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-260781@lists.php.net to get a copy of this message
Kevin Murphy wrote:
Small issue with formatting a date. If I type in this: echo date("g:i:s a \o\n l F j, Y"); the "n" character in the word "on" doesn't appear, but instead what I get is a new line in the source code. If I type it as: echo date("g:i:s a \on l F j, Y"); I get the number 8 (current month) where the n is supposed to be. Is there any way to get an "n" in there?
Use single quotes, then your \n will not be converted to a NL char -- Jim Lucas "Some men are born to greatness, some achieve greatness, and some have greatness thrust upon them." Twelfth Night, Act II, Scene V by William Shakespeare

« previous php.general (#260781) next »