To keep the story short :

After every AJAX call, I want to check the status. If the status is
302 (redirect), I want my AJAX to redirect to an URL set on "Location"
header.
My code is like this :

        <div id="session_timeout_gtbportal" ></div>
        <script type='text/javascript'>

                
jQuery("#session_timeout_gtbportal").ajaxComplete(function(event,
request, settings){
                                alert(request.status);
                                        if(request.status=="302"){
                                                alert("302 inside");
                                                
location.href=request.getResponseHeader("Location");
                                                return false;
                                        }
                });
        </script>

In Firefox, 302 status can be catch perfectly (  alert("302 inside")
will be executed ), and browser can redirect to location specified by
"Location" header. But in Internet Explorer ( I use IE 7),  alert("302
inside") is never executed. I always get 200 as status-code. I use
jQuery 1.2.6.

Anyone can help me with hint /idea how to make IE to behave exactly
the same like Firefox ?
Thank you

Reply via email to