Cannot figure out simple admin login

session_start() should be at the top of the first script that uses the $_SESSION array, the bext place unless you’re using a custom session handler is to place it right after the opening <?php in your main index file