I try to order this table by the value of check-box but I get error after i use the check box here is the code I use
[php]
Nume
Universitate
$result = mysqli_query($con,“SELECT * FROM pers”);
if(isset($_GET[‘order’]) && !empty($_GET[‘order’]))
{
if ($_GET[‘order’] == ‘nume’) $result .=mysqli_query( $con," ORDER BY nume");
if ($_GET[‘order’] == ‘universitate’) $result.= mysqli_query($con," ORDER BY universitate");
}
echo "
Nume | Universitate |
---|---|
” . $row[‘nume’] . “ | ”;” . $row[‘universitate’] . “ | ”;
mysqli_close($con);
?>
</body>
[/php]