Use echo shortcut syntax

Replace all occurrences of "<?php echo" and "<?php print" by "<?=" to
reduce noise in templates.

Note that as of PHP 5.4.0, "<?=" is always available and no longer
requires "short_open_tag" to be set.

Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
This commit is contained in:
Lukas Fleischer 2012-09-21 08:57:29 +02:00
parent 964ea083e6
commit 6102759b7c
26 changed files with 368 additions and 366 deletions

View file

@ -116,17 +116,17 @@ if ($atype == "Trusted User" || $atype == "Developer") {
$nextresult = proposal_count();
?>
<div class="box">
<p><a href="<?php echo get_uri('/addvote/'); ?>"><?php print __("Add Proposal") ?></a></p>
<p><a href="<?= get_uri('/addvote/'); ?>"><?= __("Add Proposal") ?></a></p>
<?php if ($result):
$by = htmlentities($by, ENT_QUOTES); ?>
<?php if ($off != 0):
$back = (($off - $limit) <= 0) ? 0 : $off - $limit; ?>
<a href='<?php echo get_uri('/tu/'); ?>?off=<?php print $back ?>&amp;by=<?php print $by ?>'><?php print __("Back") ?></a>
<a href='<?= get_uri('/tu/'); ?>?off=<?= $back ?>&amp;by=<?= $by ?>'><?= __("Back") ?></a>
<?php endif; ?>
<?php if (($off + $limit) < $nextresult):
$forw = $off + $limit; ?>
<a href="<?php echo get_uri('/tu/'); ?>?off=<?php print $forw ?>&amp;by=<?php print $by ?>"><?php print __("Next") ?></a>
<a href="<?= get_uri('/tu/'); ?>?off=<?= $forw ?>&amp;by=<?= $by ?>"><?= __("Next") ?></a>
<?php endif; ?>
<?php endif; ?>
</div>