can some one please tell me if these's a problem in my code
$db->orderBy('date','asc');
$schedules = $db->get("schedules");
by having these 2 lines on my page, my page shows Error 500 and if i test it on my computer on Localhost it looks fine and works perfectly. and don't know if the problem is my code or it is server side.
Thanks.
This is my code to connect to database
<?php
$db_host = "HOST";
$db_username = "USERNAME";
$db_password = "PASSWORD";
$db_name = "NAME";
$con = @mysqli_connect("$db_host","$db_username","$db_password","$db_name");
if(!$con)
{
echo"
<html>
<head>
<meta charset='UTF-8'>
</head>
<h1>Can't Connect to database</h1>
</html>";
exit;
}
?>