1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

iframe does not work in Chrome

Discussion in 'General Programming Chat' started by bumpywowus, Nov 25, 2012.

  1. bumpywowus

    bumpywowus Junior Member

    Joined:
    Nov 23, 2011
    Messages:
    125
    Likes Received:
    29
    Location:
    Where da cash at
    Hi,
    On page load I have a modalpopup. The modal Popup's source is from another page on my website, which contains an iframe. For some reason, the iframe does not load on Chrome, but loads on Firefox and IE. Any ideas?
     
  2. jazzc

    jazzc Moderator Staff Member Moderator Jr. VIP

    Joined:
    Jan 27, 2009
    Messages:
    2,468
    Likes Received:
    10,147
    You 'll have better chances to get a response if you post the relevant code.
     
  3. bumpywowus

    bumpywowus Junior Member

    Joined:
    Nov 23, 2011
    Messages:
    125
    Likes Received:
    29
    Location:
    Where da cash at
    hey

    I have jquery.js and modal.popup.js in index.html header. Here is a part of header:
    The source of the modal popup is unlock.html which contains this code:
    The way is the modal popup is called in on index.html where you click on an image, code follows:
    Any ideas why the Iframe in unlock.html will only load in Firefox and IE (not sure about safari) and not chrome?
     
  4. artizhay

    artizhay BANNED BANNED

    Joined:
    Nov 21, 2010
    Messages:
    1,867
    Likes Received:
    1,335
    I'm not on a PC to test your code, but given it's a modal pop up, I imagine the iframe CSS with absolute positioning is causing issues. Try resetting it to default styling and see if that works. Also remove the hidden overflow on the div, and see if that helps. If any of those things fix your issue, you can start from there and fix it.
     
    • Thanks Thanks x 1
    Last edited: Dec 2, 2012
  5. bumpywowus

    bumpywowus Junior Member

    Joined:
    Nov 23, 2011
    Messages:
    125
    Likes Received:
    29
    Location:
    Where da cash at
    I completely removed the style area of it, and it worked in chrome. So what should I do from here, I need it to only show a certain part of the page in the iframe with no scrolling
     
  6. bumpywowus

    bumpywowus Junior Member

    Joined:
    Nov 23, 2011
    Messages:
    125
    Likes Received:
    29
    Location:
    Where da cash at
    Another update: Just removed the position: absolute; part of the style and it still loads, it just isn't centered the way it appeared with the position: absolute; on IE.

    EDIT: If I remove the overflow: hidden and keep the position: absolute it still loads but not with the image I want, shows more than I want it to.

    So it's a combination of the two that causes it not to load?
     
    Last edited: Dec 2, 2012
  7. artizhay

    artizhay BANNED BANNED

    Joined:
    Nov 21, 2010
    Messages:
    1,867
    Likes Received:
    1,335
    If you add me on Skype I may be able to help. Hard to see what the main issue is without seeing the implementation.
     
    • Thanks Thanks x 1
  8. bumpywowus

    bumpywowus Junior Member

    Joined:
    Nov 23, 2011
    Messages:
    125
    Likes Received:
    29
    Location:
    Where da cash at
    okay I will right now.
     
  9. AshBash13

    AshBash13 Newbie

    Joined:
    Dec 20, 2012
    Messages:
    15
    Likes Received:
    0
    iframe works for me when im developing in chrome.