title: PHP redirect if not logged in
body: <p>I have been trying to make this following functionality work on my website, however I'm kinda struggling with it. Perhaps one of you can help me out?</p>
  
  <p>I am developing a website which must be inaccessible (except the login of course) unless you are logged in. I was trying to make an automatic redirect to the login page if the user isn't logged in. I'm using HTML, CSS, and PHP at the moment.</p>
  
  <p>If my remaining source is needed please tell me, I'll temporarily host the site online.</p>