0 Replies Latest reply on Oct 27, 2010 7:44 PM by Thy Venkat

    Modal Panel inside IFrame rendering problem

    Thy Venkat Newbie

      Hi,

      Encountered an issue with rendering and positioning of a rich:ModalPanel inside a Iframe.

       

      Please see the following simple test.html example:

       

      {code:xml}

      <html>
      <BODY>
      Main Page
      <br>
      <br>

      Start IFrame
      <br>

      <IFRAME SRC="http://livedemo.exadel.com/richfaces-demo/richfaces/modalPanel.jsf?c=modalPanel"

              WIDTH="100%"

              HEIGHT="2000px"

              scrolling="true">
      </IFRAME>

      </br>
      END IFRAME
      </BODY>
      </html>

      {code}

       

      The IFrame is pointing to the sample page of the rich:ModalPanel.

       

      On clicking the link in Example 1 or 2, the modal panel box isnt visible immediately. Scrolling down the page shows the modal panel.

       

      Couple of things happen here:

      1. The modal dialog is rendered in the center of the IFrame based on its width and height as expected.

      2. However the focus is thrown all the way to the top and hence the modal dialog box isnt visible.

       

      There are some pages in our application that require the modal panel to be rendered from near the bottom of the page.

       

      1. Why is the focus being set to the top of the Iframe? Can this be stopped?

      2. If not is there a workaround to scroll to modal panel so that it is visible?

       

      Thanks in advance for your help

      Thy