KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
<div> <a> Text1 <img alt="" stc="" /> </a> <a> Text2 </a> </div> I want to select all anchor elements that have text=text2 . I'm looking for something like this: $('a[text=Text2]') Edit: Why this is not working? For some some reason, it needs to be in this format: $('div').find('a').find(':contains("Text2")')
Tags (comma-separated)
Save Edits
Cancel