Redirect problem in IE7

Discussion in 'ASP .Net' started by ira.gladnick@sa.ucsb.edu, Oct 20, 2008.

  1. Guest

    I have the AcquireRequestState code listed below in Global.asax, to
    redirect users to the login page when a sesions expires.

    This works like a charm in Firefox. But in Internet Explorer 7, the
    following error message gets displayed: "Internet Explorer cannot
    display the webpage. Most likely causes: You are not connected to
    the Internet. The website is encountering problems. There might be a
    typing error in the address." If I then click the refresh button, the
    login page finally does get displayed.

    Any ideas on why IE7 seems to have a problem doing an immediate
    redirect to the login page?

    The code in Global.asax:

    Protected Sub Application_AcquireRequestState(ByVal sender As Object,
    ByVal e As System.EventArgs)
    If Session.IsNewSession Then
    If User.Identity.IsAuthenticated Then
    FormsAuthentication.SignOut()
    HttpContext.Current.Session.Clear()
    HttpContext.Current.Session.Abandon()

    FormsAuthentication.RedirectToLoginPage()
    HttpContext.Current.Response.End()
    end if
    End If
    End Sub
    , Oct 20, 2008
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. =?Utf-8?B?VHJveQ==?=

    Response.redirect does not redirect from .aspx page

    =?Utf-8?B?VHJveQ==?=, Oct 18, 2004, in forum: ASP .Net
    Replies:
    3
    Views:
    5,216
    Srowe1975
    Oct 15, 2008
  2. Phillip Vong

    Response.Redirect to a new Window in IE7

    Phillip Vong, Jan 18, 2007, in forum: ASP .Net
    Replies:
    3
    Views:
    2,529
    Laurent Bugnion [MVP]
    Jan 19, 2007
  3. Jeff Louella

    IE7 on XP vs IE7 on Vista

    Jeff Louella, Mar 1, 2007, in forum: HTML
    Replies:
    9
    Views:
    499
    Adrienne Boswell
    Mar 2, 2007
  4. Mtmartin71
    Replies:
    9
    Views:
    806
    Adrienne Boswell
    Aug 28, 2007
  5. Sal
    Replies:
    1
    Views:
    377
Loading...

Share This Page