frame collection versus gEBI

A

Andrew Poulos

If I have an IFRAME named and ID'd "main" why is it that while

document.frames["main"].name
==
document.getElementById("main").name


document.frames["main"]
!=
document.getElementById("main")
?

Andrew Poulos
 
D

David Mark

If I have an IFRAME named and ID'd "main" why is it that while

document.frames["main"].name

That is an odd mix of bracket and dot notation. Why not
document.frames.main.name?
==
document.getElementById("main").name

Certainly that assertion should be true.
document.frames["main"]
!=
document.getElementById("main")

The first one is a window object. The other is an element. Of course
they are not equal. (!)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,137
Messages
2,570,794
Members
47,342
Latest member
eixataze

Latest Threads

Top