I am currently having a problem with firefox, where all other browsers behave correctly - even IE6!
I want to redirect to a subpage, but leave a history record. As far as I know, there are 2 methods for rewriting URLs:
- window.location = "some.url"; - redirect to some.url with history record
- window.location.replace ("some.url"); - redirection without entering history
So, I have to use the first one and test in the firebug console ever working perfectly.
Now there is the weird part of this question: the same statement that worked perfectly on the console, not in some jQuery callback handler:
jQuery("#selector").bind("submit", function() { $.getJSON("some_cool_json", function(response) { var redirect_path = response.path; window.location = redirect_path; }); return false; });
where response_path set correctly, I checked it! Even the redirection works correctly, but a history record is not created.
Any ideas on this? It would be great!;)
Greetings
Joe
source share