problem in setHeader in jsp (response.setHeader("location","http://localhos

I created a simple web application .If I directly enter anypage except (login and logout ) . That need session information that i set previously .

my issue is ==> i tried to go all other pages without session information ... it wont go ..

For it ......... i set response header like this below . but my application wont go "login.html "...

what is the problem ?

if (sessionvalue == null)

{

response.setHeader("location","http://localhost:8080/start.html");

}

{

//something that display if i proper login ...

}

[580 byte] By [kannankallia] at [2007-11-27 4:47:19]
# 1
The problem is that you can't phrase the problem description and the question to be answered very clear.I don't understand you.
BalusCa at 2007-7-12 10:00:03 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 2

my application contains

start.html

login.jsp

myaccount.jsp

logout.jsp

...

I enter start.html,login.jsp,logout.jsp in the address bar . it goes to respective pages.thats not a probs

my accout.jsp is created for more number of users (session validation needed).. if i enter myaccount.jsp .. it will go to login.jsp....

how i can acheive this ?

kannankallia at 2007-7-12 10:00:03 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 3
Implement a Filter. You can find examples on Google using the keywords 'LoginFilter' and 'UserFilter': http://www.google.com/search?q=%22public+class+LoginFilter+implements+Filter%22 http://www.google.com/search?q=%22public+class+UserFilter+implements+Filter%22
BalusCa at 2007-7-12 10:00:03 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...