close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

User is active or not

Thread began 6/23/2011 9:16 am by un33k9309513 | Last modified 6/30/2011 7:34 am by Jason Byrnes | 2150 views | 7 replies |

un33k9309513

User is active or not

Hi,

userActive =1 or 0

How can I block users from logging in and display "Account Disabled", if I have userActive=0 and allow them access if userActive=1?

I have a login.php page and several pages I setup access rules for. If you would tell me the steps.

Thanks

Ed

Sign in to reply to this post

Jason ByrnesWebAssist

you cant prevent them from logging in _and_ show the message. you would need them to be logged in to show the message.

Create an access level that does not allow access to the restricted page if the userActive column is 0

on the login page, edit the authenticate user server behavior, on the third page, click the plus button so the userActive column is stored in a session

create a new access rule that uses the userAccess session and makes sure it is equal to 1.

use that access restriction rule on all of the restricted pages.


on the login page, you can use the security assist show region behavior to show the account disabled message.

Sign in to reply to this post

un33k9309513

Thanks Jason, I had to read that several times I figured out where to put everything *late night
Seems to be working. Only trouble is displaying the account disabled message.

So I have

login.php with a message "account disabled" and did SA show region "userActive"

then on profile.php which is where the login.php would direct to, I created a second SA restrict access page with the way you described below allow access userActive= 1. Now what do I put for

ifaccess denied go to:

because if I set it to go login.php it doesn't show the message it just stays there on the login.php

Ed

Sign in to reply to this post

Jason ByrnesWebAssist

on the login page, use the security assist Show Region Behavior to show your message

Sign in to reply to this post

un33k9309513

Hi

I put it on the login.php, here's what I have

<?php if(WA_Auth_RulePasses("UserActive")){ // Begin Show Region ?>
<div id="AcctDisabled">Account Disabled</div>
<?php } // End Show Region ?>

Doesn't show the message though. Now does it matter if SA show region is third in line in my server behaviors?

SA authenticate user
Recordset
SA show region (userActive)

thanks

Sign in to reply to this post

Jason ByrnesWebAssist

the order does not really matter, as long as the message is in the body of the page.

if it is still working, send a copy of the login page and the WA_SEcurityAssist/HelperGroupRules.php file

Sign in to reply to this post

un33k9309513

Hi

Is it possible to just send them to you, and not post them here?

Also another thought I had,

since userActive=1 and that means everything is Good, then shouldn't this be in reverse to work for a user who is not active userActive=0 or null ? Meaning I need to make another session and call it NotActive and make a rule called NotActive < 1, then do a show SA region set for that?

I'm only asking to save time, because if this is the case, I can try it?

thanks

Sign in to reply to this post

Jason ByrnesWebAssist

I have created a support ticket so we can look into this issue further.

To view and edit your support ticket, please log into your support history:
supporthistory.php

If anyone else is experiencing this same issue, please append to this thread.

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