• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 3017
  • Last Modified:

offsetWidth

Simply:
Which browsers support offsetWidth and offsetTop? What is the best alternate to get the width/height/top/left of an object in older versions of browsers?
Thank you
Huji
PS: Somewhere else I was told that all browsers that accept getElementById accept these offset... things as well (IE 5.0+ and NS 6.0+). Even if this is correct, it doesn't give me any idea about Konquerer, Opera, and others. SO: If you send me a link to a web page, the shows all browser compatibility issues in a list, I would be SOOOOOOOOOOOOOOOO thankful!
0
huji
Asked:
huji
  • 5
  • 3
  • 2
  • +1
1 Solution
 
COBOLdinosaurCommented:
This should give you everything you need:

http://www.quirksmode.org/viewport/compatibility.html

Cd&
0
 
devicCommented:
if a "browser" does not support offsetWidth, then this is not browser...
==================================
<table cellspacing=0 cellpadding=0 border=1>
<td div onclick=alert(this.offsetWidth)>
tested on:
IE 6.0
mozilla 1.7.2
firefox 1.0
netscape 7.1
opera 7.54
</td>
</table>
0
 
COBOLdinosaurCommented:
Opera is Mozilla based... but I'm not sure what Konquerer uses for its DOM... I've never used it or had anyone want me to support it.

Cd&
0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 
devicCommented:
i think Opera is  Opera based ;)
0
 
COBOLdinosaurCommented:
It sort of uses the same DOM, but then sticks in a few quirks of its own and then tries to pretend it is IE... but it more compatible with standards than IE, but not as close as Firefox.

Cd&
0
 
archrajanCommented:
0
 
hujiAuthor Commented:
@Cd&: Your first comment has nearly solved my problem. But I have to related questions:
>...is Mozilla based...
1) What is Mozilla? Isn't it a name of a browser? I know IE is mozilla based, but, what shoudl this mean to me, to know it is mozilla based? (Excuse me for asking a question in such a dummy's way!)
2) What do Quriks Mode and Strict Mode exactly mean?
Thanks a lot
Huji
0
 
hujiAuthor Commented:
I am closing this question here, and asking my new question in a new thread.
Follow me here:
http://www.experts-exchange.com/Web/Q_21222290.html
Thanks
Huji
0
 
COBOLdinosaurCommented:
Sorry for the delay, we must be on different parts of the planet.

For part 1) I posted in the other question.

For part 2):

Quirks mode, is the default mode that the browsers run in when they do not have a full Doctype entry.  It allows the browser to render non-standard implementations for backward compatibility with buggie earlier versions; continue to support hacks in earlier versions, and allow trash laden pages generated by Office and Frontpage to render as if they actually contained valid code.

When a doctype is add it brings the browser into compliance mode.  For most browsers that means they are about 95% to the w3c specs.  For IE it gets them up to about 80% compliance, but the differences between IE and the rest of the universe is much smaller in compliant mode.

Cd&
0
 
hujiAuthor Commented:
Thanks a lot for your both answers man! You're a nice guy.
0
 
COBOLdinosaurCommented:
Always glad when I can help a little.  Thanks for the A. :^)


Cd&
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

  • 5
  • 3
  • 2
  • +1
Tackle projects and never again get stuck behind a technical roadblock.
Join Now