Desperate! "Too many redirects occurred" error
I have 2 pages that use WA_Auth_RestrictAccess. When logged in, everything seems to work as it should. However if logged out, instead of redirecting to users_LogIn.php, the page fails to load and posts the following error:
"Too many redirects occurred trying to open “”. This might occur if you open a page that is redirected to open another page which then is redirected to open the original page."
The url temporarily gets an access check var appended: index.php?accesscheck=%2Fevents%2F2009%2F259%2Findex.php
Code at top of page is:
<?php require_once('../../../Connections/AGCI.php'); ?>
<?php require_once( "WA_SecurityAssist/Helper_PHP.php" ); ?>
<?php
if (!isset($_SESSION)) {
session_start();
}
if (!WA_Auth_RulePasses("Logged in to users")){
WA_Auth_RestrictAccess("index.php");
}?>
The second page with the same problem is at:
users_Registration.php
I'm desperate to fix this -- if any one could provide a solution it would be much, MUCH appreciated!
Thanks.