Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Call different servlets from same HTML

Status
Not open for further replies.

Vandys

IS-IT--Management
Aug 3, 2000
29
AU
Hi,
My HTML page has 3 different types of login options. Now for each login option, the user name and the password and the login type info needs to be forwarded to the servlet. How can I call different servlets from same page??
Ex. Student login passes student id and the password - calls StudentServlet

teacher login passes teacher id and password - calls TeacherServlet

parent login passes parent id and password - calls ParentServlet

Can this be done?????
 
This is not very difficult but it is hard to help you with the little bit of information that you gave. What does the HTML look like?

Possible Solutions:
1) Use separate HTML forms for each type of Login and forward to the correct Servlet.
2) Have all Login Request go to a central Controller Servlet that forwards the Request to the correct Login Servlet. Wushutwist
 
Thanks Wushutwist, I have temporarily done as per the soln. 1 but will positively try out 2nd option, as that would be a neater programming.....

Vandys
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top