G
gk
i am giving a real example.
do you use ebay or any online e-commerce portal.
there you can see a search box. in that search box , you can search for
any items . you get a result page and for each item, you get a "Bye
now" button next to it.
but as soon as you are trying to buy , you'll be getting a prompt for
login page . after your login, you again go back to the same page.
my question is, how we can go back to same page ?
i have a guess for coding..
when a user clicks for "Bye Now", the code checks whether use==null or
not. if(user==null) then response.sendRedirect(/login.jsp) and when the
user logs in what the code would do ?
you know these kind of sequences could arise.
1. user come to site and logs in
2. user did not login first but go for searcing items and then go for
"Buy Now", now he should login and get back the similar page.
its very easy if the user follows step(1)
but How do i code if the user follows step(2) because in that case , he
has to get back the page as soon as he logs in. and how do i know
,whether user is coming via step (1) or via step (2) ? if he comes via
step (2) how do i code ?
thank you
do you use ebay or any online e-commerce portal.
there you can see a search box. in that search box , you can search for
any items . you get a result page and for each item, you get a "Bye
now" button next to it.
but as soon as you are trying to buy , you'll be getting a prompt for
login page . after your login, you again go back to the same page.
my question is, how we can go back to same page ?
i have a guess for coding..
when a user clicks for "Bye Now", the code checks whether use==null or
not. if(user==null) then response.sendRedirect(/login.jsp) and when the
user logs in what the code would do ?
you know these kind of sequences could arise.
1. user come to site and logs in
2. user did not login first but go for searcing items and then go for
"Buy Now", now he should login and get back the similar page.
its very easy if the user follows step(1)
but How do i code if the user follows step(2) because in that case , he
has to get back the page as soon as he logs in. and how do i know
,whether user is coming via step (1) or via step (2) ? if he comes via
step (2) how do i code ?
thank you