10.7.5
Hey, what happened to my newlines?
In PHP, the ending for a block of code is either "?>" or
"?>\n" (where \n means a newline). So in the example above,
the echoed sentences will be on one line, because PHP omits
the newlines after the block ending. This means that you need to
insert an extra newline after each block of PHP code to make
it print out one newline.
Why does PHP do this? Because when formatting normal HTML, this
usually makes your life easier because you don't want that newline,
but you'd have to create extremely long lines or otherwise make the
raw page source unreadable to achieve that effect.
|