PC Review


Reply
Thread Tools Rate Thread

How to control session timeout in WebConfig?

 
 
=?Utf-8?B?Y2hhcmxpZXdlc3Q=?=
Guest
Posts: n/a
 
      6th Aug 2005
Hi -

I'm trying to control the error that is thrown when the session times out.
My code is as follows:

<customErrors
mode="RemoteOnly">
<error
redirect="includes/reload.aspx?iOP=1"
statusCode="Timeout" />
</customErrors>

Any ideas why this isn't working?

Thanks,
 
Reply With Quote
 
 
 
 
Tom.PesterDELETETHISSS@pandora.be
Guest
Posts: n/a
 
      6th Aug 2005
The method you use is for redirecting HTTP statuscodes like 404 not found
or 500 internal error.
There isn't such a thing as a Timeout status code. Check out http://msdn.microsoft.com/library/de...orssection.asp


Cracefully detecting a session timout can be done by placing some code at
the start of each page. Check out this discussion if it meets your needs :

http://groups-beta.google.com/group/...32a6604c9605fb

Let me know it helped you or not..

Cheers,
Tom Pester

> Hi -
>
> I'm trying to control the error that is thrown when the session times
> out. My code is as follows:
>
> <customErrors
> mode="RemoteOnly">
> <error
> redirect="includes/reload.aspx?iOP=1"
> statusCode="Timeout" />
> </customErrors>
> Any ideas why this isn't working?
>
> Thanks,
>



 
Reply With Quote
 
=?Utf-8?B?Y2hhcmxpZXdlc3Q=?=
Guest
Posts: n/a
 
      6th Aug 2005
Thanks Tom,

This helps some, and i was not clear in my previous example in using just
the work "Timeout". What i'm trying to find is the IIS generated StatusCode
for Session State timeout? I cannot seem to find this number anywhere, and i
don't want to use the general 500 statuscode error.

Thanks,

"(E-Mail Removed)" wrote:

> The method you use is for redirecting HTTP statuscodes like 404 not found
> or 500 internal error.
> There isn't such a thing as a Timeout status code. Check out http://msdn.microsoft.com/library/de...orssection.asp
>
>
> Cracefully detecting a session timout can be done by placing some code at
> the start of each page. Check out this discussion if it meets your needs :
>
> http://groups-beta.google.com/group/...32a6604c9605fb
>
> Let me know it helped you or not..
>
> Cheers,
> Tom Pester
>
> > Hi -
> >
> > I'm trying to control the error that is thrown when the session times
> > out. My code is as follows:
> >
> > <customErrors
> > mode="RemoteOnly">
> > <error
> > redirect="includes/reload.aspx?iOP=1"
> > statusCode="Timeout" />
> > </customErrors>
> > Any ideas why this isn't working?
> >
> > Thanks,
> >

>
>
>

 
Reply With Quote
 
Tom.PesterDELETETHISSS@pandora.be
Guest
Posts: n/a
 
      6th Aug 2005
Hi Charlie,

HTTP statuscodes are very general and you can't trap a session time out with
it. Take a look here :
http://www.seoconsultants.com/tools/headers.asp
http://www.helpwithpcs.com/courses/h...atus_codes.htm

Let me know if you have any more questions...

Cheers,
Tom Pester

> Thanks Tom,
>
> This helps some, and i was not clear in my previous example in using
> just the work "Timeout". What i'm trying to find is the IIS generated
> StatusCode for Session State timeout? I cannot seem to find this
> number anywhere, and i don't want to use the general 500 statuscode
> error.
>
> Thanks,
>
> "(E-Mail Removed)" wrote:
>
>> The method you use is for redirecting HTTP statuscodes like 404 not
>> found
>>
>> or 500 internal error.
>>
>> There isn't such a thing as a Timeout status code. Check out
>> http://msdn.microsoft.com/library/de...ary/en-us/cpge
>> nref/html/gngrfcustomerrorssection.asp
>>
>> Cracefully detecting a session timout can be done by placing some
>> code at the start of each page. Check out this discussion if it meets
>> your needs :
>>
>> http://groups-beta.google.com/group/...tnet.framework
>> .aspnet/browse_frm/thread/5395f03fbd3b18ff/5232a6604c9605fb?lnk=st&q=
>> Forms+authentication+and+session+expiration&rnum=1&hl=en#5232a6604c96
>> 05fb
>>
>> Let me know it helped you or not..
>>
>> Cheers,
>> Tom Pester
>>> Hi -
>>>
>>> I'm trying to control the error that is thrown when the session
>>> times out. My code is as follows:
>>>
>>> <customErrors
>>> mode="RemoteOnly">
>>> <error
>>> redirect="includes/reload.aspx?iOP=1"
>>> statusCode="Timeout" />
>>> </customErrors>
>>> Any ideas why this isn't working?
>>> Thanks,
>>>



 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Bromberg's Session Timeout Control SAL Microsoft ASP .NET 2 18th Dec 2007 08:34 PM
Session Timeout problems-web.confg session state and IIS session s =?Utf-8?B?Um9iSEs=?= Microsoft ASP .NET 4 11th Apr 2007 05:52 PM
Session Timeout control message. caldera Microsoft ASP .NET 1 26th Aug 2004 02:28 PM
Session contents lost despite Session.Timeout = 3000; and <sessionState mode="InProc" cookieless="false" timeout="300"> Carpe Diem Microsoft ASP .NET 3 23rd Feb 2004 07:10 PM
web.config session timeout and forms authentication timeout Do Microsoft ASP .NET 2 23rd Nov 2003 02:27 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 10:51 AM.