I have a menu that has several options, I want to select only the one that is active. When I give 'variable'.find_element_by_id (' key ') Selenium returns me ALL options. Does the active option have a "selected" marker, as I point to this selenium markup?
variable = nanana.find_element_by_id ('key')
<tr>
<td class="label"><label for="key"><em>*</em>Key:</label></td>
<td>
<select name="key" id="key"><option value="29972-N-PR-2">ADEMAR </option>
<option value="30632-N-PR-2" selected="selected">TEIXEIRA </option>
<option value="40914-N-PR-2">ANA </option>
<option value="16145-N-PR-2">RITA </option>
<option value="21147-N-PR-2">ANDRE </option>
<option value="52323-N-PR-2">JEANE </option>
<option value="18645-N-PR-2">JOAO </option>
<option value="22930-N-PR-2">LUIZ </option>
<option value="14015-N-PR-2">VALDYR </option>
<option value="4354-N-AM-2">VANESSA </option>
<option value="23305-N-PR-2">GARCIA </option></select>
</td>
</tr>