Unexpected tag T_ECHO in inline if
- by Lombo
I have something like this in one of my views
<li <?php $isCurrent ? echo 'class="current"' : ''?> >
<a href="SOME_LINK" class="SOME_CLASS">SOME_TEXT</a>
</li>
This causes a syntax error, unexpected T_ECHO. Changing echo for print solves the issue, but I would like to understand why I cannot use echo.