The jQuery load function is nice but how do you handle session timeouts? I used it to add new content into a div but if my session times out, the login screen appears in that div instead of in the complete page.
Is there any way to handle this?
I am using it in JSP pages.
Should I replace it all by jsp:include pages and refresh the page every time I need to adjust the page or is there a way to do this with the jQuery load function and handle session timeouts properly?
I have tried validating the session before the call, but since there isn't any call to the server, the session still seems valid until the load request finds out it has expired. So session is not null in the current page, but when the load is executed to retreive the other page, it will get the login page instead.