De code doet het allemaal goed als ik het test op de localhost.
Zodra ik het upload naar de website gaat het inloggen niet goed.
<?php
if(isset($_POST["login"]))
{
$count=0;
$res=mysqli_query($link,"select * from registration where username='$_POST[username]' && password='$_POST[password]'");
$count=mysqli_num_rows($res);
if ($count==0)
{
?>
<script type="text/javascript">
document.getElementById("failure").style.display="block";
</script>
<?php
}
else {
$_SESSION["username"]=$_POST["username"];
?>
<script type="text/javascript">
window.location="select_exam.php";
</script>
<?php
}
}
?>