Link to home
Start Free TrialLog in
Avatar of michouis
michouis

asked on

IE8 BACK button broken

I recently completed and launched an ASP.Net web site while IE7 was the standard, Ever since IE8 both we and our users have problems trying to use the BACK button which used to work just fine. In IE8 some times it works and some times it don't! Why? How do I resolve this? I already know about the need for clicking on compatability view so the layout is not screwed but how to get the BACK button to do what it is supposed to do consistently, just like it always used to. Thanks again Microsoft! :(
Oh, why not, if any one knows why we suddenly have to click compatability view and how to resolve it so we do not have to I would also appreciate it. I guess MS has nothing better to do than break things that worked just fine to begin with. Thanks,
Avatar of Omego2K
Omego2K
Flag of United States of America image

I am afraid you're going to have to post code from pages where the error occurs. The code from the previous page and current.
Avatar of michouis
michouis

ASKER

No error occurs... what happens is you are on page A. Then you click a link which takes you to page B. If you click BACK it goes back to page A, fine. BUT if you are sitting on page B and then click another link that takes you to page C, when you click BACK it goes back to page B but you can nolonger click BACK to get to page A, it is GONE. So my BACK functionality is only remembering one page back. See code:

In the Page Load event:
 
        TopBackButton.Attributes("onclick") = "history.back();return false

Open in new window

This problem is really embarassing for us. All our customers are complaining that it does nort always work. Any one have any ideas? It used to work fine prior to IE8 being released. Thanks.
Are you implementing any ajax? using response.Redirect?
I am  NOT using Ajax. I am definitely using response.redirect all over the place.
That could cause it.
If you go from page A to page B using Response.Redirect that could cause the issue because Response.Redirect tells the client that page A has temporarily moved to page B, without saying it for certain it could cause the back button to glitch in IE8. I can't be certain, try to make a test and remove the response.Redirect and use a regular link.
What do you mean by a regular link. I mean I know about <a href= etc,,, but when certain buttons are clicked I need to handle the click event, perform some sub-routines and then reponse.redirect. How do I redirect to a new page with a query string in my code behind without using response.redirect?
Thanks
You don't. Like I said this is for testing purposes only. Remove the functionality and place a normal anchor tag to go from page A to B to C. If that works then it's likely that Response.Redirect is the culprit.
ok. Lets say that response.redirect is the culprit. What do I use instead? I can't be the only one who has written an ASP .Net Web Site with BACK buttons. Even the browser's own BACK button icon gets greyed out after the 1st BACK step. This should be an easy one I think. Do most developers NOT use response.redirect? Is their a known issue with that? Sorry, but to have to test this theory with no altermative solution if the theory proves right seems like a waste of time. And I am very busy now with other pressing items. If there was a porposed altermative to using response.redirect in my scenario then I would take the time to test it knowing that if it is the culprit then follow these steps to solve....

Thanks for your suggestions.
Help please.
I am not saying Response.Redirect is the problem. It's just a troubleshooting step. Take it out and see what happens.
You know, it works fine in Firefox and Safari, gee what a surprise (frustrated). I will have to setup a hidden test web site with pages that you get to just with <a href... links to test this out. I cannot change the design of our live web site just to test theories and we only have 1 outside IP address.

But I beg this question, if it is response.redirect, what do you use as an alternative? I find it hard to believe that such a common methid causes such a big problem with such a simple thing such as browser history.

Any one else?
 
alternative add javascript to direct the browser to another page. However, I do not know for sure that it's Response.Redirect. First you need to confirm that. Modify the site on your development server or workstation.
In this large community of .Net developers, are others using response.redirect and not having a BACK button issue in IE8? This is utterly rediculous, works fine in Firefox and Safari. So very embarassing. "Your web site BACK buttons do not always work, I hate it!" are some of the comments I am getting. Unless of course they are using a real browser like Firefox or Safari, anything but IE8! I am using standard response.redirect's and <a href= tags which are all legal and common. Sometimes it works, sometimes it won't. No rhime or reason.

THIS BROKE AS OF IE8. NO ONE ELSE HAVING SUCH AN ISSUE AFTER USING MS VISUAL STUDIO 2005 WEB SITE PROJECT??

This issue should not be such a brain teaser, simple browser history back button.

Any helpful suggestions would be greatly appreciated.
There is no way you can modify the code to debug? You have no development version?
SOLUTION
Avatar of Omego2K
Omego2K
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
I guess I have the same question, why does it work in IE versions earlier than 8 and in current versions of Firefox and Safari? What has changed in IE8 and how do I become "compatible". I mean I did use an MS product, VS2005 ASP.Net VB, to develop this web site and hence I have a problem ONLY with the latest version of MS IE8.

Ebentually I will have no choice but to spend much time to try and some how debug something I suspect is not a bug on my end.

Thanks for your suggestions,
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Well uess what? It is suddenly working normally again for me and customers that I have asked. Why you ask? THE LATEST WINDOWS UPDATES. Ever since installing the recent automatic Windows updsates this problem is resolved!

So it must have been a microsoft bug, just as I suspected. All I can say is I am glad it is resolved and we do not have to look like toal idiots!

End.
glad everything worked out for you.
Glad it works for you. The latest update for me on ie8 makes my response.redirect not work now.
It was never confirmed, nor do I believe, that response.redirect had anything to do with my issue. My issue was actually a browser history issue where the BACK button was not working consistently, sometimes yes and sometimes no. The latest windows updates appears to have resolved this issue.

I have had a similar issue to yours (I think) where any button I click would send me to my default url (Home.aspx). This was, and still is, very frustrating. I have resolved it by un-installing all versions of the .Net framework up to and including .Net 2.0, re-install .Net Framework 2.0 and then 2.0 SP1 BUT STOP THERE! Do NOT install 2.0 SP2 or the same problem recurrs.

Hope this helps.