Wrox Home  
Search P2P Archive for: Go

  Return to Index  

javascript_howto thread: check data and give alert


Message #1 by "Tan Yoke Yew" <yytan@e...> on Thu, 5 Sep 2002 18:57:24 +0800
i am doing a simple search program using jsp. it contains the features like
login, logout and search. the user allow to do search even if they haven't
login. but, if the want to view the information of the book after searching,
they must login first.

i can check whether the user has login or not by checking their login id.
the question if i detected they haven't login, how can i prompt out a alert
message "Please Login Now" , after  they click ok, i will forward them to
login page like this:

if (session.getAttribute("menu") != "yes")
//...prompt alert message here ????
<jsp:forward page="login.jsp" />

thanks in advance!



  Return to Index