Click to See Complete Forum and Search --> : changing frame in a nested frameset


webrunner
06-25-2003, 09:49 PM
I want to use location.replace(url) on a frame that is nested in another frameset. So for example you have fs1 with 'two frames called 'leftframe' and 'nestedframe'. 'nestedframe' is has a frames set fs2 that has two frames 'leftnested' and 'rightnested'. I want to use location.replace(url) in the onload of the leftframe to replace the url for leftnested. It may seem stupid for me to want this but there is a spcial reason why i want to do this. Does anyone have any ideas. I tried to make it work with parent.nestedframe.leftnested.location.replace(urladdress);
or parent.frames[Help_Frames].frames[Help_Lesson].location.href=urladdress;
I know there maybe a problem with having the pages not being loaded when the call is made if that is the case how do I get around that problem. Thank you.

Khalid Ali
06-25-2003, 10:15 PM
it should work...if not I usually use the frames array and use the appropriate index for the fram..it never failes..

parent.frames[x].frames[n]......

webrunner
06-25-2003, 10:33 PM
so in this example it would be parent.frames[1].frames[0].location.replace() if say nestedframe is the second frame listed and leftnested is the first frame listed. Unfortunately it does not seem to work. it just doesn't seem to work is it because it hasn't loaded yet.

Khalid Ali
06-25-2003, 10:53 PM
if you are having these problems with the loading sequnce..then you should use the onload event of the frameset element.
For the example above...you will have to make sure that the index for the frames array is pointing to correct frame.

webrunner
06-25-2003, 11:45 PM
I don't suppose there is a way to synchronize it and allow for it so that I can still do it from that page without having to use frameset onload. I know how to do it and I can do it but there are issues. I know what I want to do is kind of crazy but the project i am working on is kind of unusual. If it is too much trouble I'll go to plan B but I really would like to at least find some solution to it. I am pretty sure that it simply not detecting it because the frames haven't fully loaded yet. So if thats the problem it would be nice if I had a way of synchronizing it, but I keep thinking about it and there does not appear to be.