1

I have a generic error page for my web application, which will kick in when the app has timed out.

Now, consider this situation. I am in a JSP, which has an iFrame in it, and the iframe is loaded with another page within my application.

Lets say, we leave this page on for the app to time out.

Now, click on any link/button inside the iframe. the error page is displayed inside the iframe !!!

Ashot Karakhanyan
  • 2,804
  • 3
  • 23
  • 28
user3347623
  • 11
  • 1
  • 2

1 Answers1

1

This is because the <iframe> is effectively a separate browser. The outer browser window cannot communicate with the code in the <iframe>, and when you click a link within the iframe, it only affects that frame.

You will need to have the links within the iframe change your parent window (see: How to force link from iframe to be opened in the parent window) or you will need to redesign your application.

Community
  • 1
  • 1
JBCP
  • 13,109
  • 9
  • 73
  • 111