Like me if you are trying to get the background-position style working in Mozilla FireFox and still un able to find the problem check how you gave the value there.
Basically, Background-Position can accept value in two parts “x” and “y”. For example,
background-position : "x y"
Of course, “x” represent the X axis where as “y” represent Y axis. Now you can define the value of both the axes in the following way.
Method |
Example |
In Word |
center top
top left |
In Pixels |
10px 200px |
In Percentage |
15% 300% |
So, if you ever wish to use Background-Position in firefox, use the Percentage method, nothing else gonna work.
Following is the workable in Firefox
background-position: 0% 10%
Following is the JavaScript style
objDiv.style.backgroundPosition="0% 10%"