View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

Authentication not redirecting to page with "Page Access" defined

Thread began 8/05/2009 12:24 pm by erinlima318673 | Last modified 8/05/2009 2:30 pm by erinlima318673 | 7010 views | 1 replies

erinlima318673

Authentication not redirecting to page with "Page Access" defined

I need to re-open a previously (accidentally) closed support ticket #106696
Below is the content I provided in the posting and the reply.
**********************************

I have 2 sets of working pages that were built last year, and both are working flawlessly -- last week I needed to create a new set of pages that connect to the a new table in the same database as the working pages, and for some reason the when I try to login using the new login page, it will not redirect to the new "protected" page. It seems that the session cookie is not being set properly and it redirects to the page defined in the "If access denied, go to:" field.

I also tried taking one of the working sets of pages and verified that the redirect was working, and then simply changed the "table" reference in the code, to the new table within the same database, and it stopped working.

I can "register" with no problem, the information is added the to the database but when I try to "Login" it will not grant access to the page with the "grant access if" code on it.

If I take the "grant access if code off of the page I am trying to protect, I can redirect to it, and I can view my profile info, and I can log out -- but if that "grant access if" code is on the page it will not work, and keeps bouncing back to the "if access denied, go to:"
page.

Here is the URL for the live LogIn page as well as the code above the html:

url= rapdownloads_LogIn.php

<?php require_once( 'Connections/conn_upstart.php' ); ?>
<?php require_once( "WA_SecurityAssist/Helper_PHP.php" ); ?><?php
if ((((isset($_POST["remembermeoption"]))?$_POST["remembermeoption"]:"") != "")) {
setcookie("RememberMePWD", "".((isset($_POST["userpassword"]))?$_POST["userpassword"]:"") ."", time()+(60*60*24*30), "/", "", 0);
}
?><?php
if (isset($_POST["LogIn"]) && !isset($_POST["remembermeoption"])) {
setcookie("RememberMePWD", "", time()+(60*60*24*30), "/", "", 0);
}
?>
<?php
if($_SERVER["REQUEST_METHOD"] == "POST"){
$WA_Auth_Parameter = array(
"connection" => $conn_upstart,
"database" => $database_conn_upstart,
"tableName" => "rapdownloads",
"columns" => explode($WA_Auth_Separator,"UserName".$WA_Auth_Separator."Password"),
"columnValues" => explode($WA_Auth_Separator,"".((isset($_POST["username"]))?$_POST["username"]:"") ."".$WA_Auth_Separator."".((isset($_POST["userpassword"]))?$_POST["userpassword"]:"") .""),
"columnTypes" => explode($WA_Auth_Separator,"text".$WA_Auth_Separator."text"),
"sessionColumns" => explode($WA_Auth_Separator,"ID"),
"sessionNames" => explode($WA_Auth_Separator,"ID"),
"successRedirect" => "rap_download_.php",
"failRedirect" => "rapdownloads_EmailPW.php",
"gotoPreviousURL" => FALSE,
"keepQueryString" => TRUE
);

WA_AuthenticateUser($WA_Auth_Parameter);
}
?>


The page I am trying to protect is:

rap_download_.php

And the code above the html on this page is:

<?php require_once( "WA_SecurityAssist/Helper_PHP.php" ); ?>
<?php
if (!WA_Auth_RulePasses("Logged in to rapdownloads")){
WA_Auth_RestrictAccess("rapdownloads_LogIn.php");
}
?>


Like I said, this code is exactly the same as the code on two other sets of pages that we currently use and they all work flawlessly -- so I am pulling my hair out trying to figure out why the new pages aren't working.

For your reference, the pages that ARE working can be accesses using the following URL:

upstart_download_.php


Thank you in advance -- I am going on day 5 with no resolution.

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...