I didn't notice this question on the site already and I am having a hard time with it.
I simply want to run a php script at the top of a html page that will check for the existence of a cookie, making in essence a password protected website. If the person browsing has the cookie, they are allowed to continue, otherwise they are redirected to a login page. I am pretty new to web development, but I was led to understand that....
<html>
I am in html!
<?php
//Code goes here
echo "I am in php!";
?>
I am back in html!
</html>
Would work...But I only get the output of the html sections.