[Webinar] Streamline your web hosting managementRegister Today


Different Logins = different page/form displayed

Posted on 1999-11-25
Medium Priority
Last Modified: 2013-12-18
What I would like to do is have 3 different levels of login to my db.

This is what I want to achieve.

I am building an app (R5) that will be accessed via a web browser. When  people visit the site they are welcomed and then when moving further inside are challanged to login (this bit I have done). What I would like to achieve is that the person who is accessing the site gets directed to a different page/form/view depending on that login.

Any ideas as to how this would best be achieved are greatly welcome.

Question by:mr880
  • 2

Accepted Solution

Alex_Gould earned 400 total points
ID: 2237374

If you setup Roles for each level of user then after they exit the initial page then the WebQuerySave agent can interogate whether they have the Role or not and redirect accordingly.

Use @URLOpen("http://url1") if you are using @Formula or if you are using Script then it's good to have a Computed for Display field (HasRole) at the top of the form determining if the user has the Role,

@If(@IsMember; @UserRoles; "[Role1]"); "Yes"; "No")

and then a simple

if doc.HasRole(0) = "Yes" then
  print "[http://url1]"
  print "[http://url2]"
end if

will redirect the browser to that page.

You can also achieve the same effect with JavaScript by creating an HTML text field with the value of HasRole
as it's value. Use this value and set location.href to the URL you want to send them to.



Author Comment

ID: 2240791

thanks for that, I think this seems to be along the right lines but I have a couple of things I am not sure about in your suggested answer, and just to say I am pretty new to notes so please bear with me.

The main thing I am confused about is this:

Even if a user is assigned a certain role the app won't know what it is until they have logged in.

The way I have the app set up at the moment is like this: I have a domain that I have registered, lets say www.mynotesapp.com when people go there they get a welcome screen and a link that says login. Clicking on the link brings up the login dialog then takes them to a new page. I was hoping that the new page they would be taken to would reflect who they logged in as but I am begining to think this might be impossible.

I have chosen this approach because I don't want to end up with a long URL that ends with &login.

Do you think that I should use a holding page that sits between the Initial welcome page and the page I want the person to eventually see.
That way the person would have logged on to the DB and the holding page could contain the code to redirect them where I want? Also is there any benefit to be had from using ACL groups as opposed to Roles

I do appeciate your help on this and have upped the points to 200 accordingly, just let me know what you think of this last suggestion and they are yours.


Author Comment

ID: 2240800
Adjusted points to 200

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This is an old article, please see an updated version of this article, located here: http://www.experts-exchange.com/articles/23619/Notes-8-5x-Windows-7-Notes-info-and-tips.html
For beginners of Lotus Notes user this is important to know about the types of files and their location supported by IBM Notes. Mostly users are unaware about how many file types are created and what their usages are. This Article is fully dedicated…
How to fix display issue, screen flickering issue when I plug in power cord to the machine. Before I start explaining the solution lets check out once the issue how it looks like after I connect the power cord. most of you also have faced this…
The video provides a quick and easy steps to migrate MBOX file to well known Outlook PST and Office 365. Besides this, it also supports and migrates more than 20 email clients of MBOX which include AppleMail, Opera, Thunderbird and SeaMonkey effortl…

608 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question