View Single Post
Old 06-16-2009, 10:44 AM   #1 (permalink)
Wildhoney
La Vida es Sueño
Advanced Programmer Top Contributor 
 
Wildhoney's Avatar
 
Join Date: Sep 2007
Location: Oldham
Posts: 2,280
Thanks: 90
Wildhoney is on a distinguished road
Plugin/Addon Do you end your PHP documents with "?>"?

Zend actually recommend that you don't place the ending PHP tag ?> because that way it prevents any white-spacing creeping in after you've ended the ?> tag.

I think we've all experienced that problem before. Usually the first thing to detect a white-space is the session class, which is unable to work when output has been started because the session class wishes to send HTTP headers. Often is the case that your document is as follows, and you spend all your time trying to find the white-space:

"?> "

Quite a few IDEs now will actually trim the document before saving and thus eliminating that issue. With Zend's recommendations, however, I can only feel one way at the moment, and that my document seems incomplete without the closing PHP tag.
__________________
The man who comes back through the Door in the Wall will never be quite the same as the man who went out.
Send a message via AIM to Wildhoney Send a message via MSN to Wildhoney Send a message via Yahoo to Wildhoney
Wildhoney is offline  
Reply With Quote