Short tags
DelusionDisclosure
Clarification
Comments (3)
Delusion
"Don't use short tags, they may be disabled."
"Don't use short tags, they're deprected."
Disclosure
First of all, short tags aren't deprecated and never have been.
Second, there are actually TWO kinds of short tags, a regular one,
<?and a shorthand for echo,
<?=Although the former can actually be disabled in configuration, the latter one "is always available regardless of the short_open_tag ini setting", as one can read on the manual page
Clarification
While ranting on short tags, do not confuse them.
<?= is all right and extremely handy in native PHP templates.
Comments:
The main issue with Short Tags is portability. Can you be 100% certain that the servers running your code will have Short Tags enabled? All the time? Forever?
No?
Then spend the extra THREE KEYSTROKES and use the full opening tags and you're 100% covered.
End of discussion.
@Petar
Actual text is:
The ASP tags <%, %>, <%=, and the script tag <script language="php"> are removed from PHP.
The only reference to "<?" says "discouraged", not "deprecated".
In PHP 7.0.0 the short tags are deprecated. This is according to the manual page you provided in the article.