<?php
session_start();
if (!isset($_SESSION['username'])) {
    header("Location: student_checkin/login.php");
    exit();
}

// Detect protocol (HTTP/HTTPS)
if (!empty($_SERVER['HTTPS']) && ('on' == $_SERVER['HTTPS'])) {
    $uri = 'https://';
} else {
    $uri = 'http://';
}
$uri .= $_SERVER['HTTP_HOST'];
header('Location: '.$uri.'/student_checkin/dashboard.php');
exit();
?>
Something is wrong with the XAMPP installation :-(