Hidden div height (changing my advice)

后端 未结 4 1699
一向
一向 2021-01-02 15:54

Ok, I was going to answer someone\'s question here on SO about why their script wasn\'t working. They loaded content into a hidden div, then got the height so they could ani

4条回答
  •  轻奢々
    轻奢々 (楼主)
    2021-01-02 16:16

    $('.hidden-element').get(0).height;
    

    gives the height from DOM element, which is set also fro hidden elements

提交回复
热议问题