Question : php stop loading page
Answered by : das-zockerteam
<?php session_start(); if (!isset($_SESSION['id'])) { header('location:../'); exit(); // <-- terminates the current script }
// close the php tag and write your HTML :)
?>
<html> <body> code code <!-- if you need another php tag somewhere else --> <?php if(1 != 2) echo '<em>PHP works :)</em>'; ?> code code </body>
</html>
Source : https://stackoverflow.com/questions/33194203/php-session-prevent-entire-page-from-loading | Last Update : Sun, 10 Jul 22