Jump to content

replace for getElementsByClassName, and cross broswer for offsetX


Nati323
 Share

Recommended Posts

OffsetX is implemented inconsistently across browsers right now. There's a discussion about the various properties here:http://www.jacklmoore.com/notes/mouse-position/There's a polyfill for getElementsByClassName if you need to support very old browsers:https://gist.github.com/eikes/2299607

Link to comment
Share on other sites

i read the first link that you gave when i search in google, but the meaning of:

 

 

This is implemented very inconsistently between broswers

they dosent say which broswers support, they only say that the imlementetion is inconsistently, whats the meaning of that?

 

thanks for the other link.

Link to comment
Share on other sites

According to the MDN page, only Firefox supports it (that information is given by Mozilla though, so it might be biased). Inconsistent means that different browsers might all have that property available, but they calculate the value differently.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...