Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    layout in iframe won't show

    Been scratching my head trying to figure this out - the problem only occurs within our system, standalone seems to be working. We use GWT to create/show/destroy our elements. The problem is only visible in IE - FF, Chrome and Safari work fine.

    We have a separate html page which contains an iframe pointing to our page. I see (in IE Developer Console) that the layouts are being created/shown. I even debug its top/bottom coordinates and call visibleAtPoint(0,0) on a VLayout and it returns true...but there is nothing visible on the page unfortunately.

    If maybe by some sort of luck, someone has encountered a similar problem in your team, please let me know if there is something in particular I should be checking.

    Let me know if you want to bother with the standalone code that works. I should also add that if I change the iframe to an object tag, it works fine.

    #2
    We don't have a record of a support incident that seems similar..

    You mentioned top and bottom coordinates - have you checked widths? Maybe the screen is rendering 1px wide?

    Have you checked isDrawn() and isVisible()?

    Have you tried looking at whether the expected DOM elements are there at all using IE's Developer Tools?

    Comment


      #3
      yup I've checked everything - at first, width and height were 0 so it wasn't drawing - the width and height I had specified were in percentage and for some reason this was not working so I changed the values to static pixel and the layouts ended up being drawn properly but still nothing on the screen.

      Actually, I did check the HTML rendered and it does not have the divs that are generated in normal circumstances (without iframes).

      Code:
      <div class="normal" id="isc_0" style="left: 0px; top: 0px; width: 1485px; height: 892px; overflow: visible; position: absolute; z-index: 200018; cursor: default;" onscroll="return page$$LoginGrid_vCentering.$lh()" eventProxy="page$$LoginGrid_vCentering">

      When I look for the layout using window["page$$LoginGrid_vCentering"] it returns null - when I do window.frames['mFrame']['page$$LoginGrid_vCentering'] it returns Permission Denied.

      Can you point me to where that div is created in js? Maybe I can debug the function and see whats going on.

      Comment


        #4
        This probably indicates that a JS error is occurring but the browser is not reporting it. You might try adding some try..catch blocks around the code to see if you can trap a JS error that's being silently ignored otherwise.

        Also, what about the surrounding HTML? Are you perhaps loading code that writes out components into the <head> instead of the <body>? Just to test, what if you move everything to the <body>?

        Finally, all HTML insertions go through Element.createAbsoluteElement() and/or Element.insertAdjacentHTML().

        Comment


          #5
          Oh geez. Bingo. Worked as soon as I moved everything into the body - by everything I mean the script tags which includes the SC js files .

          Also, what about the surrounding HTML? Are you perhaps loading code that writes out components into the <head> instead of the <body>? Just to test, what if you move everything to the <body>?
          Thanks a lot for the help!
          Last edited by acarur01; 19 Apr 2011, 11:34.

          Comment

          Working...
          X