Jquery find table cell where value is X

前端 未结 2 1061
被撕碎了的回忆
被撕碎了的回忆 2021-02-20 01:26

I am trying to find a where the value is 5. It is a calender so there will only be one 5 value.

2条回答
  •  一向
    一向 (楼主)
    2021-02-20 02:06

    You can use filter method:

    $('td').filter(function(){
        return $(this).text() === '5'
    })
    

提交回复
热议问题