Forum Moderators: open

Message Too Old, No Replies

multiple iframe loads from one link

multiple iframe loads from one link

         

greumach

9:38 pm on Aug 7, 2003 (gmt 0)

10+ Year Member



I know there have been posts regarding multiple iframes and how to load them with one link. However, I have tried a few different coding and none have work. If anyone could help me out, it would be much appreciated.

Thanks

tedster

3:55 am on Aug 8, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Welcome to WebmasterWorld, greumach.

If we have bad advice on other threads, it would be valuable to correct it specifically. Help us out with a bit more detail -- what code have you tried and how did it fail?

greumach

4:26 am on Aug 8, 2003 (gmt 0)

10+ Year Member



Well, I tried a couple versions of some similar code. Perhaps I'm not applying it correctly, but here are the ones I used.

function doTwo(pageA,pageB)
{
(numberoneiframe.location=pageA);
(numberTwoiframe.location=pageB);
}

<a href="javascript:doTwo('page1.html','page2.html')">Link</a>

AND

function loadFrames(page1,page2) {
eval("window.frames.menu.location='"+page1+"'");
eval("window.frames.contents.location='"+page2+"'");
}

<a href="javascript:loadFrames('page1.htm','page2.htm')">Link</a>

The first error I got (with the first set of code) was that "numberoneiframe" was not defined. The error with the second set of code was the "window.frames.menu.location" is null or not an object.