Home Articles FAQs XREF Games Software Instant Books About Feedback Search Site-Map
irt.org logo

Q792 How can I load a file into a layer?

irt.org | Knowledge Base | DHTML | Q792 [ previous next ]

Q792 How can I load a file into a layer?

Try:

<A HREF="javascript:load('test2.htm','myLayer',400)">Load</A>

<SCRIPT LANGUAGE="JavaScript"><!--
function load(url,id,width) {
    if (document.layers)
        document.layers[id].load(url,width);
    else
        if (window.frames.length > -1)
            window.frames[id].location.href = url;
}
//--></SCRIPT>

<IFRAME ID="myLayer" WIDTH="400" HEIGHT="400"></IFRAME>

<LAYER ID="myLayer" STYLE="width: 400; height: 400;">
This is some text This is some text This is some text This is some text
This is some text This is some text This is some text This is some text
This is some text This is some text This is some text This is some text
This is some text This is some text This is some text This is some text
This is some text This is some text This is some text This is some text
This is some text This is some text This is some text This is some text
This is some text This is some text This is some text This is some text
This is some text This is some text This is some text This is some text
This is some text This is some text This is some text This is some text
</LAYER>

Provide feedback ...
AddThis Social Bookmark Button

Provide feedback ... AddThis Social Bookmark Button


Last Updated: 30th March 2008. Maintained by: Martin Webb
irt.org liability, trademark, document use, privacy statement and software licensing rules apply.
Copyright © 1996-2008 irt.org, All Rights Reserved.