Using Logins to Show Different Screens

Nate Maingard shared this question 5 years ago
Answered

Hi There.


So I've read and watched everything I can find on using 'logins' in prototyper.


Simply put, when user is not logged in, I want to show a login box when they click specific menu items/buttons, which I've managed to get started on.


Now, once user is logged in, I don't want a login box to pop up, which is what I can't seem to get right. Is there any way to keep the information used to log in and get the website to refer to that every time a user clicks a button which has a different response based on logged in being true or false?


I have a data master set up with usernames and passwords to play around with. When I use one of the usernames and passwords, it goes to the page I intend, which is great. It's just that when I click the same menu button again it shows the login box again, but I'm already 'logged in'. I hope this is making sense, it's hard to explain.


This is how I show the hidden login box to an un-signed in user:


0d42abc3c0e300392b35fa4807e6967f


This is how I tried to make sure that box wouldn't appear once the user was signed in, using an 'else' command, using variables to record entries into the 'login' and 'password' text boxes:


My goal is to be able to realistically simulate the different experiences logged in and logged out visitors would experience.


Your assistance would be much appreciated.


Thank you in advance


Nathan

Comments (11)

photo
1

Hi,


maybe you can play with show/hide elements and variables. I'm thinking something like this.


1. When the user writes his username and password correctly, add a "set value" event and calculate a new variable called userin, for example, and give it the value "1".


2. In all the screens, add an "on page load" event that checks the value of this variable. If it's 1, hides. the login panel. If it's 0, don't do anything.


If you need more help write us back!

photo
1

Thanks for the awesome feedback Albert! Great minds think alike (or fools run in packs...something like that anyway), I've been fiddling around with something similar to what you're saying.


Where should I add the "set value" event? I'm thinking on the 'Sign in' button, and activate the event when the login is correct? I'm still very new to all this, so working it out as I go along.


Could you perhaps write out an example I could edit to my own uses?


Thanks again!

photo
1

The set value must be add in the "sign in" button.


Write us to jim.support@justinmind.com and I can edit your prototype.

photo
1

So I've set userin to be 1 when sign in is clicked with correct username and password in their fields. The login box still shows itself although I set that when userin = 1 it should go straight to the page logged in users should see

photo
1

I am using a Master Menu, could that have something to do with it? It just seemed crazy to have to change every menu in separate screens every time I change what it links to!

photo
1

Hello again Albert.


So, is it possible to have something which is in the template appear above the other layers in different screens? I have a hidden login box which won't appear on top of other layers when I make it visible.


This is the same template you were working on with me yesterday.


Thanks


N

photo
1

All the elements from a template will appear behind any element that you include in the screen.

photo
1

So if I want to have a hidden login which appears when clicking certain elements, I should have that as a master which I paste into every screen individually?

photo
1

You can't invoke an element from the template clicking on an element from the screen. In some way, the elements from the template can only invoke from the template.

photo
1

Ok, fair enough. Thanks

photo
1

Thinking the most simple solution is to create a login screen which opens via pop up command when clicking relevant buttons or menu items.