hi,
What does this PHP syntax mean: <?=
Is the same of <? or <?php ?
thanks
What does this PHP tag mean: <?=
Moderator: General Moderators
Re: What does this PHP tag mean: <?=
<?=...?> is the same as <? echo ...; ?>. Both require that short tags be enabled.
-
internet-solution
- Forum Contributor
- Posts: 220
- Joined: Thu May 27, 2010 6:27 am
- Location: UK
Re: What does this PHP tag mean: <?=
Its the output tag
The above is same as below
Although it saves you typing, this is not recommended, if you change server with this code might not work. Same applies to short tag <?. These two tags have to be enabled in your php.ini file.
Code: Select all
<?= [output here] ?>Code: Select all
<?php echo "some output"; ?>