close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

User and Admin Logout?

Thread began 1/15/2010 11:34 am by woodenboat | Last modified 4/20/2010 2:45 pm by Eric Mittman | 5952 views | 26 replies |

woodenboat

User and Admin Logout?

I recently purchased the Registration Solution Pack. After setting it up, everything seems to be working ok except I don't see any log out links on the user pages or admin pages? What am I missing?

I do see a the users_LogOut.php file. Do I just create links to that for logging out?

I don't see one for the Admin pages?

thanks.

Sign in to reply to this post

Eric Mittman

You just need to link to this page in order to make use of it. If you create a link to the logout page any user that is logged in that clicks on the link will be logged out. If the user is not logged in then they will be sent to the login page.

If you want a user logout page for the admin area you can use the same page as you are for the users but you will need to modify some of the things at the top. Currently lines 1-6 look like this in the logout page:

php:
<?php require_once( "WA_SecurityAssist/Helper_PHP.php" ); ?>

<?php
if (!WA_Auth_RulePasses("Logged in to users")){
    
WA_Auth_RestrictAccess("users_LogIn.php");
}
?>



If you made a copy of this page and put it in the admin area you would need to change these lines to be like this instead:

php:
<?php require_once( "../WA_SecurityAssist/Helper_PHP.php" ); ?>

<?php
if (!WA_Auth_RulePasses("Administrator")){
    
WA_Auth_RestrictAccess("users_LogIn.php");
}
?>



You would also need to make a link to this page in your admin area.

Sign in to reply to this post

woodenboat

Thanks for your help!

Sign in to reply to this post

Eric Mittman

Your welcome, let us know if you have any other questions or if you run into any issues.

Sign in to reply to this post

woodenboat

Another issue

I need to add a couple of textarea's to users_Registration.php
I do have access to the Extension Library.
I've added two textarea's using dreamweaver.
I open users_Registration.php and go to the Server Behaviors panel, I double click on "Insert Record" and get this error:

While executing onLoad in WAAB_Insert_SB.htm, the following JavaScript error(s) occured:
In File "WAAB_Insert_SB": initializeUI is not defined

I can't even find that file?
So what did I do wrong?

Sign in to reply to this post

woodenboat

Just found the answer here:

showthread.php?t=3977&highlight=winfilecache+appdata

Sign in to reply to this post

woodenboat

Making an Admin LogOut page

Originally Said By: Eric Mittman
  You just need to link to this page in order to make use of it. If you create a link to the logout page any user that is logged in that clicks on the link will be logged out. If the user is not logged in then they will be sent to the login page.

If you want a user logout page for the admin area you can use the same page as you are for the users but you will need to modify some of the things at the top. Currently lines 1-6 look like this in the logout page:

php:
<?php require_once( "WA_SecurityAssist/Helper_PHP.php" ); ?>

<?php
if (!WA_Auth_RulePasses("Logged in to users")){
    
WA_Auth_RestrictAccess("users_LogIn.php");
}
?>


If you made a copy of this page and put it in the admin area you would need to change these lines to be like this instead:

php:
<?php require_once( "../WA_SecurityAssist/Helper_PHP.php" ); ?>

<?php
if (!WA_Auth_RulePasses("Administrator")){
    
WA_Auth_RestrictAccess("users_LogIn.php");
}
?>


You would also need to make a link to this page in your admin area.  



I duplicated the users_LogOut.php and put it in the Admin directory. I changed the code as you discribed above and put a logout link on one of the admin pages. But when selecting the logout, I'm taken to the Admin LogIn and the "You are logged in. You may proceed..." text is still showing and I'm not logged out?

Here is code from my admin LogOut page:
<?php require_once( "../WA_SecurityAssist/Helper_PHP.php" ); ?>
<?php
if (!WA_Auth_RulePasses("Administrator")){
WA_Auth_RestrictAccess("users_LogIn.php");
}
?>
So what did I do wrong?

Sign in to reply to this post

Eric Mittman

For some reason it seems that you are not passing the access restriction rule in place on this page. You can just remove the restriction, it should not make a different.

remove this:

php:
<?php

if (!WA_Auth_RulePasses("Administrator")){
    
WA_Auth_RestrictAccess("users_LogIn.php");
}
?>
Sign in to reply to this post

woodenboat

thanks, now logout works.

Sign in to reply to this post

zanimul379168

I'm having the same issue with logging the Admin out. I've tried both fixes as described above, yet I get this error message after removing the require once stanza:

Fatal error: Call to undefined function: wa_auth_rulepasses() in /stop-them.org/members/Admin/logout.php on line 2

Other than this issue it's working well.

Sign in to reply to this post
loading

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