Click here to get back home

Frames that haven't loaded and document location

 HomeNewsGroups | Search | About
 comp.infosystems.www.authoring.html    Post an article   get this group's latest topics as an RSS feed add this group's latest topics to your My MSN content add this group's latest topics to your My Yahoo content
Subject Author Date
Frames that haven't loaded and document location BerlinBrown 01-30-2008
Posted by BerlinBrown on January 30, 2008, 11:53 am
Please log in for more thread options
We have a complicated setup; where we have to use frames and iframes.
The page where this javascript is invoked is at the page that has an
iframe called bottom. The iframe has frames that have frames.

My question; without touching the other pages (I can only have
javascript on this page); how can I set the document location of the
other sub frames, especially if the bottom.location page hasn't even
been set yet.

NO, I cannot change the frame structure.

E.g.
bottom.location='/a/bottomset.html';

This page has frames

My Page
<iframe name="bottom" id="bottom" src="empty_page.html" />

My Javascript on My Page.
        function onloadTracking() {
                try {
                        bottom.location='/a/bottomset.html';
                        bottom.frames[1].frames[1].frames[0].location='/a/page';
                        bottom.frames[1].frames[1].frames[1].location='/a/blank_wht.html';
                } catch(e) {
                        alert(e);
                }

        }

Posted by BerlinBrown on January 30, 2008, 12:15 pm
Please log in for more thread options
> We have a complicated setup; where we have to use frames and iframes.
> The page where this javascript is invoked is at the page that has an
> iframe called bottom. The iframe has frames that have frames.
>
> My question; without touching the other pages (I can only have
> javascript on this page); how can I set the document location of the
> other sub frames, especially if the bottom.location page hasn't even
> been set yet.
>
> NO, I cannot change the frame structure.
>
> E.g.
> bottom.location='/a/bottomset.html';
>
> This page has frames
>
> My Page
> <iframe name="bottom" id="bottom" src="empty_page.html" />
>
> My Javascript on My Page.
> function onloadTracking() {
> try {
> bottom.location='/a/bottomset.html';
>
bottom.frames[1].frames[1].frames[0].location='/a/page';
>
bottom.frames[1].frames[1].frames[1].location='/a/blank_wht.html';
> } catch(e) {
> alert(e);
> }
>
> }


bottom.location='/a/bottomset.html';

The issues is that, these won't get set because the bottomset page
hasn't loaded yet.

>
bottom.frames[1].frames[1].frames[0].location='/a/page';
>
bottom.frames[1].frames[1].frames[1].location='/a/blank_wht.html';

Posted by BerlinBrown on February 1, 2008, 11:11 am
Please log in for more thread options
>
>
>
> > We have a complicated setup; where we have to use frames and iframes.
> > The page where this javascript is invoked is at the page that has an
> > iframe called bottom. The iframe has frames that have frames.
>
> > My question; without touching the other pages (I can only have
> > javascript on this page); how can I set the document location of the
> > other sub frames, especially if the bottom.location page hasn't even
> > been set yet.
>
> > NO, I cannot change the frame structure.
>
> > E.g.
> > bottom.location='/a/bottomset.html';
>
> > This page has frames
>
> > My Page
> > <iframe name="bottom" id="bottom" src="empty_page.html" />
>
> > My Javascript on My Page.
> > function onloadTracking() {
> > try {
> > bottom.location='/a/bottomset.html';
> >
bottom.frames[1].frames[1].frames[0].location='/a/page';
> >
bottom.frames[1].frames[1].frames[1].location='/a/blank_wht.html';
> > } catch(e) {
> > alert(e);
> > }
>
> > }
>
> bottom.location='/a/bottomset.html';
>
> The issues is that, these won't get set because the bottomset page
> hasn't loaded yet.
>
> >
bottom.frames[1].frames[1].frames[0].location='/a/page';
> >
bottom.frames[1].frames[1].frames[1].location='/a/blank_wht.html';

I tried to use something with addEventListener; something like the
following.

                function goForIt(evt) {
                        alert('testing');
                }
                function testWaitLoop() {
                        var bottomIFrame = document.getElementById("bottom");
                        bottomIFrame.location = 'bluepage.html';
                        bottomIFrame.addEventListener("load", goForIt, true);
                }

Posted by Jonathan N. Little on February 1, 2008, 12:19 pm
Please log in for more thread options
BerlinBrown wrote:
>>
>>
>>
>>> We have a complicated setup; where we have to use frames and iframes.

Ah, the joys of frames!

>>> The page where this javascript is invoked is at the page that has an
>>> iframe called bottom. The iframe has frames that have frames.
>>> My question; without touching the other pages (I can only have
>>> javascript on this page); how can I set the document location of the
>>> other sub frames, especially if the bottom.location page hasn't even
>>> been set yet.
>>> NO, I cannot change the frame structure.
>>> E.g.
>>> bottom.location='/a/bottomset.html';
>>> This page has frames
>>> My Page
>>> <iframe name="bottom" id="bottom" src="empty_page.html" />
>>> My Javascript on My Page.
>>> function onloadTracking() {
>>> try {
>>> bottom.location='/a/bottomset.html';
>>>
bottom.frames[1].frames[1].frames[0].location='/a/page';
>>>
bottom.frames[1].frames[1].frames[1].location='/a/blank_wht.html';
>>> } catch(e) {
>>> alert(e);
>>> }
>>> }
>> bottom.location='/a/bottomset.html';
>>
>> The issues is that, these won't get set because the bottomset page
>> hasn't loaded yet.
>>
>>>
bottom.frames[1].frames[1].frames[0].location='/a/page';
>>>
bottom.frames[1].frames[1].frames[1].location='/a/blank_wht.html';
>
> I tried to use something with addEventListener; something like the
> following.

You do realize that good ol' IE does not support "addEventListener", but
MS has their own limited "attachEvent"

>
>                 function goForIt(evt) {
>                         alert('testing');
>                 }
>                 function testWaitLoop() {
>                         var bottomIFrame = document.getElementById("bottom");
>                         bottomIFrame.location = 'bluepage.html';
>                         bottomIFrame.addEventListener("load", goForIt, true);
>                 }

Since you are stuck with frames and required to use JavaScript you might
get a better response on a JavaScript group:

comp.lang.javascript

--
Take care,

Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com

Posted by Bergamot on February 1, 2008, 11:53 am
Please log in for more thread options
BerlinBrown wrote:
>
> My question; without touching the other pages (I can only have
> javascript on this page); how can I set the document location of the
> other sub frames, especially if the bottom.location page hasn't even
> been set yet.

This isn't an HTML issue.
comp.lang.javascript is over there ->

--
Berg

Similar ThreadsPosted
How to link to a location within another document? November 13, 2005, 2:10 pm
A HTML document can be converted to XHTML document. January 31, 2005, 8:58 am
making it so a particular image is the first thing loaded August 9, 2007, 11:47 pm
Webpage renders differently when loaded from Internet February 4, 2007, 4:39 pm
little icon on location bar: HOW?? August 17, 2004, 10:26 am
Removing "www." from location bar? August 11, 2006, 3:27 am
Location header question December 9, 2005, 11:29 am
Alt cgi-bin location for virtualhost domain August 4, 2008, 6:37 pm
question on location obtained by website - How ? June 12, 2005, 2:46 pm
URI scheme for (geographical) map or address location? To-Do? March 9, 2007, 12:41 pm

Our other projects:

Art Dolls, Fairies and Mermaids - Sunnyfaces.net

Roy's Linux, Programming and Search Engines messages

1-Script XML SitemapXML Sitemap