Not done any coding for a LONG time. I want to get the value of the opacity for a element.
I'm using Nightly 9.0a1. Also, from what I have read Firefox should us this to SET the opacity style:
But this does not see to work in the CSS. In the CSS the value ranges from 0 to 1. So 50% would be 0.5
My current function stops working before executing the alert command. I'm guessing i'm trying to get the style value wrong?
I'm using Nightly 9.0a1. Also, from what I have read Firefox should us this to SET the opacity style:
Code:
obj.style.opacity = opacity/100;
My current function stops working before executing the alert command. I'm guessing i'm trying to get the style value wrong?
Code:
function fadeByid(objId) { if (document.getElementById) { obj = document.getElementById(objId); opacity = obj.style.opacity; alert(opacity); if (opacity >= 100) { setOpacity(obj, opacity); opacity -= 10; window.setTimeout("fadeByid('"+objID+"','"+opacity+")", 100); } } }