jquery - Get height of image in 2nd LI -


In this code to achieve the height of the image contained in the 2nd layer, struggling to get the right jQuery ... any idea ?

  & lt; Ul class = "example" & gt; & Lt; Li & gt; & Lt; Img src = "example.jpg" width = "500" height = "500" & gt; & Lt; / li & gt; & Lt; Li & gt; & Lt; Img src = "example.jpg" width = "500" height = "500" & gt; & Lt; / li & gt; & Lt; / Ul & gt; Use    

or eq is zero-index based Therefore it starts with 0

  $ ('example li: eq (1) img'). Height ();    

Comments

Popular posts from this blog

sql - Postgresql record to array -

c++ - Cmake produces file extensions in static library archives -

java - Clearing application data programatically android -