Clearing IFrame SRC property works from Mozilla/FireFox but not IE

Discussion in 'Javascript' started by Robert Oschler, Jul 28, 2005.

  1. I have Javascript code that clears the SRC property of an IFRAME during the
    onload event of a web page, if a certain flag is set. In Mozilla/FireFox
    the clearing of the SRC property works fine and the browser does not attempt
    to load the document. That document being the one that was specified in the
    SRC property, before it was erased.

    In Internet Explorer, the code appears to clear the SRC property properly.
    If I trace the code, the MSDEV debugger does show the SRC property as empty
    after the statement that clears it. However, the browser still tries to
    load the document specified in the SRC property despite the fact it does
    *not* display the contents of the document in the IFRAME.

    I know it's still trying to load the document because the document is a PHP
    document running in the Zend PHP debugger, with a breakpoint set in it.

    How can I stop IE from trying to load the document?

    Thanks.
     
    Robert Oschler, Jul 28, 2005
    #1
    1. Advertising

  2. Robert Oschler

    Jedi Fans Guest

    Re: Clearing IFrame SRC property works from Mozilla/FireFox but notIE

    Robert Oschler wrote:
    > I have Javascript code that clears the SRC property of an IFRAME during the
    > onload event of a web page, if a certain flag is set. In Mozilla/FireFox
    > the clearing of the SRC property works fine and the browser does not attempt
    > to load the document. That document being the one that was specified in the
    > SRC property, before it was erased.
    >
    > In Internet Explorer, the code appears to clear the SRC property properly.
    > If I trace the code, the MSDEV debugger does show the SRC property as empty
    > after the statement that clears it. However, the browser still tries to
    > load the document specified in the SRC property despite the fact it does
    > *not* display the contents of the document in the IFRAME.
    >
    > I know it's still trying to load the document because the document is a PHP
    > document running in the Zend PHP debugger, with a breakpoint set in it.
    >
    > How can I stop IE from trying to load the document?
    >
    > Thanks.

    It would help to have a URL or a snippet of script [URL = better]
     
    Jedi Fans, Jul 29, 2005
    #2
    1. Advertising

  3. Robert Oschler

    cosmic foo Guest

    "Robert Oschler" <> wrote in message
    news:...
    > I have Javascript code that clears the SRC property of an IFRAME during

    the
    > onload event of a web page, if a certain flag is set. In Mozilla/FireFox
    > the clearing of the SRC property works fine and the browser does not

    attempt
    > to load the document. That document being the one that was specified in

    the
    > SRC property, before it was erased.
    >
    > In Internet Explorer, the code appears to clear the SRC property properly.
    > If I trace the code, the MSDEV debugger does show the SRC property as

    empty
    > after the statement that clears it. However, the browser still tries to
    > load the document specified in the SRC property despite the fact it does
    > *not* display the contents of the document in the IFRAME.
    >
    > I know it's still trying to load the document because the document is a

    PHP
    > document running in the Zend PHP debugger, with a breakpoint set in it.
    >
    > How can I stop IE from trying to load the document?
    >
    > Thanks.
    >
    >


    make sure src is empty before the page loads?
     
    cosmic foo, Jul 29, 2005
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Aidan
    Replies:
    4
    Views:
    506
    Neredbojias
    Jun 7, 2007
  2. Soren Vejrum
    Replies:
    4
    Views:
    623
    Lasse Reichstein Nielsen
    Jul 5, 2003
  3. David Springthorpe

    Works OK In IE6 But Not In Mozilla Firefox 0.9.2

    David Springthorpe, Aug 22, 2004, in forum: Javascript
    Replies:
    1
    Views:
    87
    Michael Winter
    Aug 22, 2004
  4. Greg
    Replies:
    3
    Views:
    156
  5. Replies:
    7
    Views:
    147
    Lasse Reichstein Nielsen
    Apr 4, 2006
Loading...

Share This Page