close ad
Databridge V2 with MySQLi support IS Now Available!
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Logins and out display

Thread began 10/26/2012 5:34 pm by Php | Last modified 11/09/2012 10:33 am by Jason Byrnes | 1850 views | 15 replies |

Php

Logins and out display

Hi there Ive set up site on local server everything working where I display login / register , when a customer logs in I want the login/ register to change and show that I'm logged in and logout?

Kind regards

Sign in to reply to this post

Jason ByrnesWebAssist

Use the Security Assist Show region behavior.

Select the Login and register buttons, then go to the server behaviors panel (Window -> Server Behaviors) Click the plus button and select WebAssist -> Security Assist -> Show region. from the list of rules, select the "Not Logged Into <your users table>" (where <your users table> is the name of your users table) rule.

Add your logout button and the logged in message, then select them in design view, and add a second show region behavior, this time select the "Logged Into <your users table>" rule

Sign in to reply to this post

Php

Originally Said By: Jason Byrnes
  Use the Security Assist Show region behavior.

Select the Login and register buttons, then go to the server behaviors panel (Window -> Server Behaviors) Click the plus button and select WebAssist -> Security Assist -> Show region. from the list of rules, select the "Not Logged Into <your users table>" (where <your users table> is the name of your users table) rule.

Add your logout button and the logged in message, then select them in design view, and add a second show region behavior, this time select the "Logged Into <your users table>" rule  



hi jason i have this working but i want to display the person name who is log in at the moment it only says you have logged in with no nam, how can i do this?

Sign in to reply to this post

Php

not showing name

the show region behaviour workd whereby when a user is logged in, in my header it shows the log out button, However where the log out button is, i would also like to display the users name. I know this is created dynamically but don't know how to do this. Please can you tell me how to do this. Thank you.

Sign in to reply to this post

Jason ByrnesWebAssist

to show the logged in users name, you need to edit the authenticate user server behavior on the login page to have it store the name in a session variable.

on the login page, open the server behaviors panel and double click the authenticate user server behavior.

On the Sessions tab, Click the plus button and select the name column to have the name stored in a session.

on the page, where you want to show the name, go to the bindings panel expand the session collection and drag the User name session to the page.

Sign in to reply to this post

Php

Bindings

Thanks for replying, but the bindings is gonna be on the login page, so how can I get to be displayed on the header of every page from the template. How can I make this possible?

Kind regards
Yas

Sign in to reply to this post

Jason ByrnesWebAssist

once set a session is available to any page, including the login page, in your site.

Sign in to reply to this post

pupweb

testing the session variable

Hi Jason,

Thanks for answering this question as I was going to ask the very same question! To test on my testing server with Jane Doe user, do I have to logout and log back in so the session variables will be set in the refreshed page?

Thanks, -David

Sign in to reply to this post

Jason ByrnesWebAssist

yes, you have to logout, then back in in order to set the session.

Sign in to reply to this post

Php

sorted

its sorted thanks you
kind regards
yas

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