-- Kexiao Liao <[EMAIL PROTECTED]> wrote
(on Tuesday, 07 August 2007, 08:33 AM -0700):
> I am new to Zend Framework, what does the tag("<?=") in index.phtml template
> file mean? It seems the tag("<?=") is not a php standard tag. Does anyone
> can give more detail explaination if this tag? Thanks
>
> Kevin
>
> <? foreach ($this->tables as $tableName): ?>
> <li>
> "/zfgrid/grid/show/table/<?= $tableName ? ">
> <?= $tableName ?>
>
> </li>
> <? endforeach; ?>
These are PHP short tags, which is an option you can set in your php.ini
or via ini_set(). As somebody else noted:
<? : PHP open tag
<?= : shorthand for <?php echo ...
It's recommended to use the long form of '<?php' for opening tags, as
it's more compatible with the XML and XHTML specifications. However,
most examples using Zend_View use <? to keep the syntax succinct; I
personally use short tags in my view scripts, in part to set them apart
from normal PHP scripts.
--
Matthew Weier O'Phinney
PHP Developer | [EMAIL PROTECTED]
Zend - The PHP Company | http://www.zend.com/