Hi all,
We are having an internal discussion on whether or not to enable PHP's short_open_tag by default in Zend Server - hopefully, some of you might have an opinion on that.
Currently, it is off - that means you cannot use short PHP opening tags such as <? and <?= in your code, unless you enable it. There is a lot of code out there that requires short_open_tag to be on.
On the other hand, many believe having short_open_tag enabled is a bad practice.
What is your opinion? If you vote, please, also comment and explain why you believe so.
Let the flame wars begin ;)
Shahar.
Quick survery: short_open_tag support on or off by default?
Re: Quick survery: short_open_tag support on or off by default?
**Dons the flame retardant suit**
I personally believe that a default configuration should reflect best practices, leave it off and if the development team is having to support legacy code they should already be aware of this problem
I personally believe that a default configuration should reflect best practices, leave it off and if the development team is having to support legacy code they should already be aware of this problem
Re: Quick survery: short_open_tag support on or off by default?
I think that the purpose of the default configuration is not to enforce particular practice but to have people start using PHP and running their applications with maximum ease and maximum success rate. Each roadblock on this way, even with best intentions in mind, only makes it harder for people to use it.
Re: Quick survery: short_open_tag support on or off by default?
Exactly. I think it should be left to the developers preference whether or not to enable this option. I personally use it however it isn't in best practice to release code formatted with short tags, that's just how it is.ddt wrote:I think that the purpose of the default configuration is not to enforce particular practice but to have people start using PHP and running their applications with maximum ease and maximum success rate. Each roadblock on this way, even with best intentions in mind, only makes it harder for people to use it.
Re: Quick survery: short_open_tag support on or off by default?
Probably is better to consider each release individually... in community release, i think ti's better to let it on: many user would be neophytes (as i am) and would use embedded or legacy code rather than typing their own (at least at beginning). In Commercial, instead, user would be mostly experienced programmer or developer testing and running their own (formatted) code, free to chose if they need to turn it on.
Re: Quick survery: short_open_tag support on or off by default?
personally i believe that short_open tags should be optional based on the developer and the application. while some might thing it is bad practice to use them i have made many programs that require them. so i think it is better to allow an option for it.