Hi. I would like to find if a specific selection or element is inside another node, but I would like to go from the bottom up. For example if a text node is inside a form node.
<form id="theForm">
...
other nodes
nested nodes
my selection: <p>Test me</p>
...
</form>
<for id="anotherForm">
...
doesn't matter
...
</form>
What I would like to do is to move up from node text "Test me" until I reach the tag form and than get the id of this tag (for compare...)
<form id="theForm">
...
other nodes
nested nodes
my selection: <p>Test me</p>
...
</form>
<for id="anotherForm">
...
doesn't matter
...
</form>
What I would like to do is to move up from node text "Test me" until I reach the tag form and than get the id of this tag (for compare...)