KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
I am currently trying to find the parent of a parent of an element. I have a link being clicked that is in a <td> , and I'd like to get the <tr> object. Why wont "$(this).parent().parent()" work? What will? Thanks, Brendan Edit: It appears an error in my syntax was throwing the whole thing off. "$(this).parent().parent()" does in fact work, but I wound up going with $(this).closest('tr')" because it seems like the most efficient solution.
Tags (comma-separated)
Save Edits
Cancel