<?php
  session_start();
  if(!isset($_SESSION['visited'])){
    header("Location: glowna.php");
    exit();
  }
?>

<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8">
    <title>Moja strona WWW</title>
  </head>
  <body>
    <p>
      Witamy na stronie index2.php.
    </p>
    <p><a href="glowna.php">glowna.php</a></p>
    <p><a href="index1.php">index1.php</a></p>
  </body>
</html>
