Two Laptop Bag
The moose likes JSP and the fly likes hi Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Make it so: Java DB Connections & Transactions this week in the JDBC forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "hi" Watch "hi" New topic


singhpore shankar

Joined: Jul 04, 2005
Posts: 2
i have a login form and if a user enters username password correctly we should direct the user to some page.
else if it is incorrect we should redirect to login form back
and give him a message and i need to verify usename and password from backend data(i am using ms-access) and JSP
so i need some help
i need source code for this

Niki Nono
Ranch Hand

Joined: Mar 20, 2005
Posts: 256
you will have to use response.redirect(); function of jsp.
do some R&D on the function and i am sure you will find the correct implementation.

Life called,so here I am.<br />Cheers<br />Niki.:-)
lekha phijo

Joined: Oct 09, 2003
Posts: 29
let the action tag in your jsp direct to another jsp which is like a controller.
This jsp should use response.redirect as mentioned by Niki to ur error page or ..

Good Luck!!!
Yuriy Zilbergleyt
Ranch Hand

Joined: Dec 13, 2004
Posts: 429
Wouldn't that be response.sendRedirect()?
Niki Nono
Ranch Hand

Joined: Mar 20, 2005
Posts: 256
my mistake yuriy.
it should be response.sendRedirect but let singhpore look into the details.
I agree. Here's the link:
subject: hi
jQuery in Action, 3rd edition