[thelist] get height of div with js after changing it?
Saila, Craig
Craig.Saila at bgminteractive.com
Thu Aug 15 14:20:01 CDT 2002
> -----Original Message-----
> From: david currey [mailto:dave at state51.co.uk]
> Sent: August 15, 2002 3:03 PM
> but after i call a script which changes the div (innerhtml)
> and makes it taller, the value returned to me is still 300px.
> is there anyway to get the 'new' height.
Theoretically, what you're doing should work, for example, if
DIV[id="test"] has the height declared inline (or via JS), this finds
both the old and new value:
nObj = document.getElementById("test")
alert(nObj.style.height)
nObj.style.height = "400px"
alert(nObj.style.height)
Although I'm not sure, I'm guessing the "innerHTML" might be causing the
problem.
--
Cheers,
Craig Saila
------------------------------------------
craig at saila.com : http://www.saila.com/
------------------------------------------
More information about the thelist
mailing list