• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
  • Liutauras Vilda
  • Campbell Ritchie
  • Tim Cooke
  • Bear Bibeault
  • Devaka Cooray
  • Jeanne Boyarsky
  • Knute Snortum
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Ganesh Patekar
  • Stephan van Hulst
  • Pete Letkeman
  • Carey Brown
  • Tim Holloway
  • Ron McLeod
  • Vijitha Kumara

Determining admin from general  RSS feed

Ranch Hand
Posts: 312
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

I have an application where we have 2 types of users (general users & administrators).
I have a very similar kind of login page for both. The only difference is the header
portion which says General Login Page & Admin Login Page.

Now I want to achieve something like this when the request is a general request I
want to show General Login Page. For this I have set the home.jsp in my Welcome page.
This page redirects to a url like this action/GeneralAction whose url I have mapped
in the url-pattern section of my web.xml like this

I am using FORM based authentication. So whenever from home.jsp the action gets called
the user is prompted with a Login.jsp which i have specified in the <login-config> tag.

Till this its fine.

But now I want to show the admin login page. How can i configure this.
Even if i have url pattern action specified in url-pattern say action/AdminAction
how can i force the admin login page to the Administrators & not the general login page.

I am using Weblogic7 (sp6)

It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!