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

c# - The item with identity 'Id' already exists in the metadata collection. Parameter name: item -

sql - PostgreSQL automatically update row at specific date -

jsp - No mapping found for HTTP request with URI with annotation config Spring MVC and Jetty -