Displaying a document on the web site

How can I display specific document
on the web site according to the person authenticated to the database?
I know I can use:
@URLOpen("http://host/database/view/Document?OpenDocument ") where Document can be a key. The problem is that the key isn't
permanent but changes according to the user authenticating to the database.
How can I still get this parameter from the user(user's name)and display the appropriate document using this formula?
(or is there another way to do that?)
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

You have a couple of possiblities for solving the issue.

First of all you can use Cookies to load in the Users name and redirect them to the approprate document.  Use the WebQueryOpen on a default form and then redirect them to the document you want.  For more information on using Cookies with Domino try WWW.gettips.com, WWW.lotus411.com and the Lotus Developer discusion groups.

If you don't want to use Cookies then you are going to have to force a login on the user.  Set the ACL on your database to Anonymous = NoAccess.  This ensures that everyone will have to login in to access the database.  Next either use the Session Based login available on the Domino Server to redirect them to a login page which will have the approprate logic to open the document for them, or else once again have a default form the will use the $$Return and JavaScript to redirect onLoad or the WebQueryOpen event to redirect.

Hope this helps.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Lotus IBM

From novice to tech pro — start learning today.