I would like to know how to get the first and last parent of a class set (.date) that is contained in a div within an element.
Here is an example code sequence:
<table>
<tr>
<td>Nome</td>
<td>Sobrenome</td>
<td>Data Nascimento</td>
</tr>
<tr>
<td class="range">Thiago</td>
<td class="range">Cunha</td>
<td class="range">
<div class="date">
22/12/1988
</div>
</td>
</tr>
<tr>
<td class="range">Caroline</td>
<td class="range">Cunha</td>
<td class="range">
<div class="date">
22/12/1988
</div>
</td>
</tr>
<tr>
<td class="range">Thalita</td>
<td class="range">Cunha</td>
<td class="range">
<div class="date">
22/12/1988
</div>
</td>
</tr>
<tr>
<td class="range">Thiago</td>
<td class="range">Cunha</td>
<td class="range">22/12/1988</td>
</tr>
<tr>
<td class="range">Caroline</td>
<td class="range">Cunha</td>
<td class="range">
<div class="date">
22/12/1988
</div>
</td>
</tr>
<tr>
<td class="range">Thalita</td>
<td class="range">Cunha</td>
<td class="range">
<div class="date">
22/12/1988
</div>
</td>
</tr>
</table>
Note that in the code, only some divs are given the .date class.
Thank you for the collaboration.