Reputation: 15
I have a Table where i want to Display time someone has worked. This comes from a mySql a Field should Display the minutes, and if a other field ist true, then it should be add "high" after the minutes
I tried this:
Print "<td width=50px>";
PRINT $info['minutes'] if($info['high'] == 0 ) {echo "Hoch"} ;
and got this:
Parse error: syntax error, unexpected 'if' (T_IF) in C:\xampp\htdocs\callinfo.php on line 63
Someone can Help? :)
Upvotes: 0
Views: 65
Reputation: 4043
You need to space out your code if you can't handle parse errors. Also, print/echo are pretty much same, use one or the other, not both, make your life easier in the future when you're looking for specific code.
PRINT $info['minutes'];
if ( $info['high'] == 0 ) {
echo "Hoch";
}
Upvotes: 2
Reputation: 1472
you need to add ;
PRINT $info['minutes'] ;
if($info['high'] == 0 )
{
echo "Hoch";
}
Upvotes: 1