skaterdav85 Posted March 12, 2011 Share Posted March 12, 2011 Is the window an object property of the navigator object?I was looking at http://www.comptechdoc.org/independent/web...avaobjheir.html and it says the window object is a property of the navigator object, but when you run the following peice of code, the alert does not come up. Any ideas? if (navigator.window) { alert(navigator.userAgent);} Link to comment Share on other sites More sharing options...
jeffman Posted March 12, 2011 Share Posted March 12, 2011 That page is useless, and the design is seriously 1995-ish. Hideous background, default font. It's got a current doctype, but I bet that and the Google stuff were tacked on long after it was written. I haven't messed with the window.status property in a LONG time. In the mid 90s it was THE THING to do.I think by "object hierarchy" the author was trying to describe a conceptual framework. Some of the things refer to actual objects, but that seems more coincidence than anything.Anyway, the answer to your question is a definite NO. Link to comment Share on other sites More sharing options...
skaterdav85 Posted March 12, 2011 Author Share Posted March 12, 2011 well i wanted to find a hierarchical tree of everything available to a JS developer. Link to comment Share on other sites More sharing options...
jeffman Posted March 12, 2011 Share Posted March 12, 2011 I don't think I've ever seen one. The closest is what I see in a DOM Inspector. If you wanted to open the whole thing up and see it at once, it would fill a wall. Link to comment Share on other sites More sharing options...
Synook Posted March 13, 2011 Share Posted March 13, 2011 DOM inspectors do a good job of this - you can see that document is a property of window, etc. You will also see that there is actually no clear, uh, "hierarchy", though, with many things existing in the global scope. Link to comment Share on other sites More sharing options...
skaterdav85 Posted March 13, 2011 Author Share Posted March 13, 2011 ya there doesn't seem to be a clear hierarchy. I was just aware that document is a property of window and both are global. I wasn't sure how navigator fit in, but based on my test, i think navigator is 'on the same level' as window, rather than being a property of window. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.