jQuery next() with selector is not finding specified element based on class
I have an HTML structure that looks like:
And I have a jQuery reference to the
<a> as a result of the
onClick of the
When I examine (as a watch variable):
However, when I use:
It comes back with an empty object. It seems it should be pulling in that
<div>, but I can’t seem to determine why it’s skipping over it.
It’s because the
.next() method only returns the next adjacent element. If the very next sibling element doesn’t have class
.csvTable-box, nothing is selected.