> And if the 'short tag' method is useful enough for people, why 'exclude'
it from a standard?
Because no matter what installation of PHP you have, this works:
<?php echo $var; ?>
But this:
<?=$var?>
Or this:
<? echo $var; ?>
Or this:
<% echo $var; %>
...is made invalid if short_tags are disabled (and the last only works with
ASP tag support, and I'd say 90% of PHP users don't have it enabled). And if
the tags are turned off, guess what happens to all the code between those
tags? woops ;)
And as mentioned, short_tags must be disabled on .xml pages. Or they at
least "should" be.
While there are work-arounds, if you didn't use short-tags you wouldn't ever
have a problem with any standard unless <?php becomes part of their markup,
lol. And if it does, they will have to be "dealt with" :)
--
Plutarck
Should be working on something...
...but forgot what it was.
"Michael Kimsal" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Yes yes I'm a zealot. :)
>
> If the people defining the PEAR standards really were that interested in
> standards,
> why include alternate ways of doing something? <?=$blah;?>
> And if the 'short tag' method is useful enough for people, why 'exclude'
it
> from a standard? This notion of 'PEAR standards' does irk me some,
because
> it's been so long in coming, and people are deferring to it before it's a
reality.
>
> At least, that's the impression that I get.
>
>
>
> Philip Olson wrote:
>
> >
> > 1. Is PHP4+ specific
> > 2. Won't work if short_open_tag setting is off (in php.ini)
> > - One reason to turn this off, to enable XML support
> > 3. Doesn't follow up-and-coming PEAR coding standards
> >
> > And as you've seen, many don't even know what <?= is. You'll find
zealots
> > on both sides of this use, the choice is yours. ;-)
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]