I want to click on a pagination link at the bottom which is the next to <td class="cur">
. In this case, "Pg 2".
<td class="cur"><a aria-label="Pg 1" class="pg" href=""></a></td>
<td><a aria-label="Pg 2" class="pg" href=""></a></td>
Then again on Page 2, click on a link which is the next to <td class="cur">
. In this case, "Pg 3".
<td><a aria-label="Pg 1" class="pg" href=""></a></td>
<td class="cur"><a aria-label="Pg 2" class="pg" href=""></a></td>
<td><a aria-label="Pg 3" class="pg" href=""></a></td>
and so on.
How do I implement this in JavaScript/jQuery?