Gernot Back: Finding Parents for Orphaned Pages

Beitrag lesen

Hi Anni,

No wonder! You named your frame "mainFrame" in the frameset, ...

<frameset rows="119,*,32" onLoad="fillFrame();" cols="*" frameborder="NO" border="0" framespacing="0">
  <frame src="top.html" name="topFrame" scrolling="NO" noresize >
  <frameset cols="153,*" frameborder="NO" border="0" framespacing="0">
    <frame src="nav.html" name="leftFrame" scrolling="YES" noresize>
    <frame src="main.html" src="javascript:parent.blank" name="mainFrame">
______________________________________________________________^^^^^^^^^^
  </frameset>
  <frame src="bottom.html">

... but on the other hand you call it "main" in the function.

function fillFrame() {
    parent.main.location.href = pageURL;
         //^^^^
  }

Simply give it the same name in both cases and your script will work without errors.

Gruß Gernot