Hello, On my social network. There are "home" links that take you to the appropriate index if you are signed in or out. There is a "index.php", that if you are browsing the site signed out, it takes you there, and if signed in, and hit "home" it takes you to "index_signedIn.php"
This is working fine for me. The problem is, when I close the window, and open it back up, its on the "index.php" even if you are signed in,and can allows you to continue in a signed in manner. Someone helped me set up the init.php, and I can not see anything in there that would relate to this.
If you have a idea what the problem may be, and want to help, please let me know what code you may need, if any.
thanks in advance
in my masthead I have these links ( and on the footer as well )
<div id="social_tag">
<?php if($auth) { ?>
<a href="index_signedIn.php"><img src="styles/images/social_tag.png" border="0" /></a>
<?php }else{ ?>
<a href="index.php"><img src="styles/images/social_tag.png" border="0" /></a>
<?php } ?>
</div>
if your session times out this happens:
function enforce_auth() {
global $auth;
if(!$auth) {
header("Location: signin.php?return=" . $_SERVER['REQUEST_URI']);
exit;
}
}
and this is on the pages that we don't want people to be able to go to if they are singed out, and right now it dumps you to the index (as it should,)
enforce_auth();
just need it to take you to index_signedIn.php when the window closes and reopens and you are still signed in