close ad
Install the LAtest Updates to Work with CC 2017 and CC 2018
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Admin not logging out

Thread began 5/02/2010 11:04 pm by mora398588 | Last modified 5/12/2010 12:40 pm by Eric Mittman | 1129 views | 5 replies |

mora398588

Admin not logging out

I have added log out functionality to my admin side. However, when the log out button is clicked, it takes me to the log in page, but the session is still active. How do I cancel out the session completely so the administrator is forced to sign in again?

Please see my attached log out file and log in file.

Attached Files
admin_LogOut.zip
users_LogIn.zip
Sign in to reply to this post

Eric Mittman

On the login page there is an access restriction rule:

php:
<?php

if (!WA_Auth_RulePasses("Administrators")){
    
WA_Auth_RestrictAccess("ssl/admin/users_LogIn.php");
}
?>



This rule will not allow you access to the logout page unless you are logged in as the admin. If you want the logout page to logout anyone regardless of how you are logged in then you should remove this code from the top of the logout page.

Sign in to reply to this post

mora398588

Thank you for the information. However, your recommendation did not appear to work. Well, the page did redirect to my logout page; however, when I attempted to log back into the administrator back end, the page had me logged in still. I noticed that there are cookie variables attached to the admin login page. Does the user registration solution pack incorporate auto login cookies or remember me cookies into the admin log in page?

What I am ulitmately wanting is to ensure that when a person is logged out of the admin back end and they attempt to log back in again, they will be prompted to provide the user name and password code all over again. I want to remove any auto log in features.

Thank you!

Sign in to reply to this post

Eric Mittman

On the logout page is code to unset the session variables. If the session variables are no longer set then you should be logged out. In the default URSP files the admin login does not contain any cookie references, it just works with the posted values from the admin login page.

Once you go to the logout page you should be logged out. If you are still logged in after you go to this page there must be something setting the session variables again. Please post back with a current copy of your admin login page and the logout page you are working with.

A good way to see what is in the session when you are on the login page is to use a vardump like this to see all of the values:

php:
if(!session_id()) session_start()

print("<pre>");
var_dump($_SESSION);
print("</pre>");



You can put this in at the top of the page to see the values, this will let you know just what is in the session.

Sign in to reply to this post

mora398588

Admin not logging out

Per your request, I have attached a copy of my admin log in and log out page. Thank you for taking the time to look at my files. It would greatly appreciate if we can correct this problem.

Attached Files
users_LogIn.zip
users_LogOut.zip
Sign in to reply to this post

Eric Mittman

I have added the session code to your login page, please use this version of the page to test out what values are in the session. When you first go to this page login and then go back to this page to see what is printed at the top. Once you have done this go to the logout page to logout then go back to the login page. You should see what is in the session after you logout. Please post back with all of the values that you are getting after you login and after you logout.

If there are any passwords present you can mask them.

Attached Files
users_LogIn.zip
Sign in to reply to this post

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...