First off:
Sorry for my bad English and sorry if this question has already been answered (I feel that it should had) but ive been looking like a mad man but then again I also lack the proper English terms to locate the right question/answers :|
In any case, to the problem:
I need to (using javascript/*monkey) locate: a name="JustDoIT" and from that position 'back-step' to an div ID or Class and remove it.
Example: html -> body -> div.main -> div#textRNG -> div.static -> a[name:JustDoIT]
Where 'div#textRNG' is the DIV i want to delete but can't specifically target because 'RNG' keeps changing.
Dealing with the 'a' tag is not enough.
Ive been thinking of doing a loop going through all the div#textRNG then div.static to reach the a tag but this route is a lot more intensive and demanding than just finding the right a tag from the start and take two steps and delete the right div.
That's if it's even possible.
I appreciate all help with this!
EDIT
- Just plain javascript if possible
- Clarification: I need to remove (grandparent?) DIV based on content inside the 'A tag' inside the same tree(?)