Possible Duplicate:
Are PHP short tags acceptable to use?
In PHP there are different short tags like <? ................... ?>, <?=$hello;?>.
But I wanted to know, if they should be avoided as much as possible? and Why?
Possible Duplicate:
Are PHP short tags acceptable to use?
In PHP there are different short tags like <? ................... ?>, <?=$hello;?>.
But I wanted to know, if they should be avoided as much as possible? and Why?
Yes.
<?xml ... ?>They aren't standard, are being deprecated, add little, if no, savings, clutter code, make it hard to read, cause weight gain and hair loss in some cases.
People advocating, or demonstrating, various PHP based libraries with the use of short tags are doing the programming community a disservice. Short tags are one of the never used features in a professional enviornment. Going into programming with the idea that short tags are "okay" is one of the worst moves you can make.
YES and they're going to be removed from PHP 6 so if you consider future compatibility, simply don't use them.
Also, see them in terms of security:
PHP Short Open Tag: Convenient Shortcut or Short Changing Security?
This question has already been answered well here: http://stackoverflow.com/questions/200640/are-php-short-tags-acceptable-to-use