jquery - Detect the height auto using javascript -
I have a In the second order of words, I want to get the height of the div without considering the white space from the bottom. Is there any way I can do that? How can you calculate and add height of children? Something like this: then in jQuery Edit: Or if you want to do something normal: / P> div with a certain height (ex: 500px). This div contains some HTML block elements. What I would like to achieve is using javascript to find out at which height my devices will be, if I set the height of that fixed height automatically.
< Code> & lt; div id = "# someId" style = "height: 500px;" & gt; & lt; p & gt; my paragraph & lt; / p & gt; & lt; h1 & gt; my title & Lt; / h1 &
var height = $ ('# someId & gt; p'). () + $ ('# SomeId & gt; h1'). Height ();
var height = 0; $ ("#someId"). Child (). (Function () {height = height + $ (this) .hit ();})
Comments
Post a Comment