I want to get the text that is inside the <option>TEXTO</option>
tag. The situation is as follows:
<select xmlns="http://www.w3.org/1999/xhtml" id="page1:form_section:form1:selectListCampus" name="page1:form_section:form1:selectListCampus" class="form-control" size="1" onchange="OnChange_Campus(this);"><option value="">Selecionar uma Opção</option><option value="a0PA0000007bDQ7MAM" selected="selected">Exemplo 1</option><option value="a0PA0000007bDQCMA2">Exemplo 2</option></select>
I have tried document.getElementById('page1:form_section:form1:selectListCampus').innerText
to retrieve the text "Example 1", but to no avail.