[Home]  [Edit this page]  [Recent Changes]  [Special Pages]  [Help
HowToJavaScriptOpenNewPageInIframe

How to open a new page in an iframe?

Iframes - just like frames - are child windows of the window object. You can reference an iframe by its index number in the frames collection, or by its id/name in the frameset.

window.frames[0].location.href="some.htm";
window.frames.myIframe.location.href="pic2.jpg";


Related threads:
IFRAME: is location.href working in any browser??

Java Script FAQ

last edited (April 19, 2004) by leeos, Number of views: 2029, Current Rev: 5 (Diff)

[Edit this page]  [Page history]  [What links here]  [Discuss this topic]  [Printer Friendly]  

Members

Username:

Password:


Register
Forgot Password?




Programmers Heaven - for .NET, Java, C/C++ and WEB Developers!
© 1996-2008 Community Networks Ltd. All rights reserved. Reproduction in whole or in part, in any form or medium without express written permission is prohibited. Violators of this policy may be subject to legal action. Please read Terms Of Use and Privacy Statement for more information. Development by Tore Nestenius at .NET Consultant - Synchron Data.