i want to direct user to another page after succesful login. below is my code. how to resolve this?
$result = mysqli_query($mysqli, $query);
//$result = mysqli_multi_query($mysqli, $query);
$data = mysqli_fetch_array($result);
$data= var_dump($data);
echo $data;
if($data != "NULL"){
header("Location:home2.php");
}
else {
echo "sorry" ;
}