Forum Moderators: open

Message Too Old, No Replies

show page inside an iframe

         

zedrik00

1:37 pm on Jun 15, 2003 (gmt 0)



I have a splash page in my site and what I want to happen is that when I click a link (eg. news.htm) a new window with an iframe pops up and loads news.htm in the iframe. Is there a javascript solution?

pls help me

tedster

8:00 pm on Jun 15, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Welcome to WebmasterWorld, zedrik00.

First, I apologize if this doesn't answer your issue. I may not be completely understanding your problem.

Yes, you can use JavaScript to open a new page (or you can use target="_blank"). Then the html for that new document can contain an iframe for a second document - that's straight HTML.

Just use the window.open() javascript method (also called pop-up windows by many people). You can find a discussion about it, complete with code, on our Generic Javascript thread [webmasterworld.com], message 4.

zedrik00

1:31 pm on Jun 17, 2003 (gmt 0)



actually, what I want to happen is this - I have a page index.htm which has a lot of links. When you click one of the links say gallery.htm, a new window (index2.htm) opens with an iframe in it and in that iframe, I want to have gallery.htm open in it. see [deadlydisease.net...] this is what I want to happen but instead of opening _self I want it to open in a new window

futureX

3:41 pm on Jun 17, 2003 (gmt 0)

10+ Year Member



open in _blank and i'm not sure why you're using the iframe but you would have to specify the iframe url in index2.html