jQuery: Get one of a set of selected elements
- by Rosarch
There are several elements that are selected by $("#foo"). $("#foo").text() returns the text of each element concatenated together. I just want the text of one element. What is the best way to do this?
$("#foo")[0].text() fails.