jquery: how can you select texts not surrounded by html tags?

后端 未结 7 2201
Beer

Vodka
rum
whiskey

how can you select beer ? or rum ? in jquery ? they are not surrounded by any html tags....

7条回答
  •  孤独总比滥情好
    2021-01-18 16:20

    It looks to me that your text should actually be a list (ol/ul). This would then give you some semantic hooks for jQuery and make things a whole lot easier.

提交回复
热议问题