You are here: Re: [PHP] Weird html - No "real" <cr> « PHP « IT news, forums, messages
Re: [PHP] Weird html - No "real" <cr>

Posted by "Gustav Wiberg" on 12/17/05 09:22

Ok, thanx!:-)

/G

----- Original Message -----
From: "Brady Mitchell" <bradym@ext.usu.edu>
To: <php-general@lists.php.net>
Sent: Saturday, December 17, 2005 12:35 AM
Subject: RE: [PHP] Weird html - No "real" <cr>


> Hi
>
> Yes, but I assume that
>
> echo "<hr>Kontroll rad i textfil:$rowsInTextFile av
> $totalRowsInTextFile<br>";
>
> would render a <newline> ?
>
> /G

Echo does not automatically add a newline, you would have to use \n to
get newlines with the echo statement:

echo "<hr>Kontroll rad i textfil:$rowsInTextFile av >
$totalRowsInTextFile<br>";

Will display the line break in the webpage as expected, but to get the
source code displayed to have the line break you would need to use:

echo "<hr>Kontroll rad i textfil:$rowsInTextFile av >
$totalRowsInTextFile<br>\n";

Brady

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

 

Navigation:

[Reply to this 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

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