Today this topic may be the cloudiest and most heated in all of PHP.
Here's the factual history of our poor little short_open_tag directive:
------------------------------------------------
php.ini values : short_open_tag
------------------------------------------------
PHP 4, 5_0
* Default behaviour : on
* php.ini-dist : on
* php.ini-recommended : on
PHP 5_1, 5_2:
* Default behaviour : on
* php.ini-dist : on
* php.ini-recommended : off
PHP 5_3:
* Default behaviour : on
* php.ini-development : off
* php.ini-production : off
------------------------------------------------
php.ini descriptions : short_open_tag
------------------------------------------------
In 5_2 our reason for discouraging it is:
; - short_open_tag = Off [Portability]
; Using short tags is discouraged when developing code meant for
redistribution
; since short tags may not be supported on the target server.
; Allow the <? tag. Otherwise, only <?php and <script> tags are
recognized.
; NOTE: Using short tags should be avoided when developing
applications or
; libraries that are meant for redistribution, or deployment on PHP
; servers which are not under your control, because short tags may not
; be supported on the target server. For portable, redistributable code,
; be sure not to use short tags.
In 5_3 it's:
; This directive determines whether or not PHP will recognize code
between
; <? and ?> tags as PHP source which should be processed as such. It's
been
; recommended for several years that you not use the short tag "short
cut" and
; instead to use the full <?php and ?> tag combination. With the wide
spread use
; of XML and use of these tags by other languages, the server can
become easily
; confused and end up parsing the wrong code in the wrong context. But
because
; this short cut has been a feature for such a long time, it's
currently still
; supported for backwards compatibility, but we recommend you don't
use them.
------------------------------------------------
This history strongly suggests PHP is hoping and subtly forcing the
world to stop using this directive, and although it's not deprecated
the wording and treatment makes it feel it could be any day now. This
situation must be clarified before 5_3 is released, and will likely
require our BDFL to do it.
In related news, what came of this RFC? It still says "Under
Discussion":
- http://wiki.php.net/rfc/shortags
Regards,
Philip
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php