PHP echo tip
Tired of doing <?php echo $foo; ?>
?<br>
Just do <?= $foo; ?>
and it will echo the $foo variable!
<br>
<? and <?= are called short open tags, and are not always enabled (see the short open tag directive) with PHP 5.3 or below (but since PHP 5.4.0, <?= is always available).<br><br>
see reference
Written by Tiago Almeida
Related protips
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Php
Authors
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#