Hi Antwort ,
     Thanx a lot for ur help.. Now i am able to create new session and if i not
perform any operations in that page on the specified time. that page is not comming
and if i click refresh button new page is comming... Well ............ But my
problem is while i entering into my web page the first screen is blank in the same
way while the page is expired after the particular time if i click any link that
page also blank....... can u give me some tips so that while i am entering my
web-page it should not come blank and it the same way after the page expired, some
message should come...

Thanx in advance

cheers
venkatesh



[EMAIL PROTECTED] wrote:

> Hi,
> to create a user-session you may try the following code in the doGet
> (...)/doPost (...) - handling-Methods :
>
>         HttpSession oSession = roRequest.getSession (false);  // try to get an
> exisiting session
>
>         if (oSession != null)
>         {
>                 // OK, anyone is been connected for the n-th time
>
>                 // continue ....
>                 performTask (....)
>         }
>         else
>         {
>             // - user tries to connect the first time, no cookie on the client
> -> no session
>             // - sessiontimeout, all userdata are lost
>             // this behaviour occurs too if you use an clustered webserver since
>  all sessiondata residents only on one machine (!!!)
>             // you can't determine, why the session is invalid
>             oSession = roRequest.getSession (true);  // get a new session
> without any attributes in
>
>             // perhaps an errormessage or a login-handling or both
>         }           :
>
> All user-sessions will be invalidated by tomcat automatically. The timeout is
> defined in the WEB.XML in your %TOMCAT_HOME%/conf - Directory. Out-of-the-box
> this parameter is initialized with 30. This means, after approximately 30
> Minutes the user-session will be invalidated. The next HTTP-Request will run
> into the ELSE-case described above. Try any other values   :-)
>
> venkatesan <[EMAIL PROTECTED]> am 15.02.2001 12:10:14
>
> Bitte antworten an [EMAIL PROTECTED]
>
> An:   [EMAIL PROTECTED]
> Kopie:     (Blindkopie: Ralf Bode/13/LBSH/DE)
>
> Thema:    session creation?
>
> Hi All,
>       I am creating web applications using servlets. can anybody tell
> that simple session creation for a particular user and invalidate after
> a specific time.
>
> Thanks
>
> cheers
> venkatesh
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, email: [EMAIL PROTECTED]
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, email: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

Reply via email to