Im getting an Error:
FATAL ERROR: Function name Must be a string in C:\xampp\localhost\student\viewgrades.php on line 78.
I wanted to make an if Statement if the grade is more than 75 then it should echo 'passed', but if the calculated grade is below 75 i should 'echo failed'.
Sorry for the code structure my knowledge for PHP is still limited
<?php
$resultp = mysql_query("SELECT * FROM prelcent");
$row = mysql_fetch_array($resultp);
$prelcent=$row['percentage'];
$resultpp = mysql_query("SELECT * FROM midcent");
$row = mysql_fetch_array($resultpp);
$midcent=$row['percentage'];
$resultppp = mysql_query("SELECT * FROM precent");
$row = mysql_fetch_array($resultppp);
$precent=$row['percentage'];
$resultpppp = mysql_query("SELECT * FROM fincent");
$row = mysql_fetch_array($resultpppp);
$fincent=$row['percentage'];
$remark = (($pre*$prelcent)+($mid*$midcent)+($prf*$precent)+($fin*$fincent));
if ($remark() >75) <<<<<Line 78 {
$rem1 = "echo 'passed!';";
} else {
if ($remark()<75) {
$rem1 = "echo 'failed';";
}
}
echo "<td>". $rem1 ."</td>"
?>