I'm not understanding why this below code not redirecting, I had destroy the sessions, so the condition should be true, but its not redirecting to this page,
<?php
session_start();
if(!isset($_SESSION['userid'])) {
header('Location: Login.html');
exit;
}
?>
but in logout php the redirection working well.
<?php
session_start();
session_destroy();
header('Location: Login.html');
exit;
?>
EDIT
I could see a redirection call in the Chrome developer tool, but its not actually redirecting
Please help me to understand my fault in the code.