Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

looping through all frames

1 view
Skip to first unread message

Axel Nennker

unread,
Dec 30, 2009, 5:13:36 AM12/30/09
to
Hi,

when I loop through all the frames like this:

var frames = doc.defaultView.frames;
for ( var i = 0; i < frames.length; i++) {
var frame = frames[i];

sometimes the variable frame is undefined!
How can this be?

I added code to detect this but I am still wondering if this might be
a bug.
A page that triggers this is
http://v.daum.net/%EC%A7%80%EB%B6%95%EB%9A%AB%EA%B3%A0%ED%95%98%EC%9D%B4%ED%82%A5&news_id=5270445?RIGHT_VIEW=R3

cheers
Axel

Eric Jung

unread,
Jan 4, 2010, 3:56:03 PM1/4/10
to dev-ext...@lists.mozilla.org
On Wed, Dec 30, 2009 at 5:13 AM, Axel Nennker
<ignis...@googlemail.com> wrote:
> Hi,
>
> when I loop through all the frames like this:
>
>                var frames = doc.defaultView.frames;
>                for ( var i = 0; i < frames.length; i++) {
>                        var frame = frames[i];
>
> sometimes the variable frame is undefined!
> How can this be?
>


Just a guess, but maybe another script is setting the frame to
undefined or null.

0 new messages