Hi, I'm having problems getting a script to work. When a certain option value is selected it is supposed to enable a text field. However, it's not working and I'm not sure why. Here's the code:
javascript:
Code:
function checkProbSelect() {
        var probSelect = document.getElementById("helpFormProblemType");
        var otherSelect = document.getElementByID("otherProblemText");     
        if(probSelect.selectedIndex.value == "Other")
        {
            alert("selected other");
            alert(probSelect.value);         
            otherSelect.disabled = false;
            
        } else {               
            otherSelect.disabled = true;
        }    
    }
markup:
Code:
<label for="${status.expression}">Problem Type: <span class="star">*</span></label>
                        <select name="${status.expression}" class="select_long" id="helpFormProblemType" onchange="checkProbSelect();">
                            <option value="">pick one</option>
                            <option value="Navigation" <c:if test="${status.value == 'Navigation'}"> selected="true"</c:if>>Navigation</option>
                            <option value="Printing" <c:if test="${status.value == 'Printing'}"> selected="true"</c:if>>Printing</option>
                            <option value="Advertising" <c:if test="${status.value == 'Advertising'}"> selected="true"</c:if>>Advertising</option>
                            <option value="Search" <c:if test="${status.value == 'Search'}"> selected="true"</c:if>>Search</option>
                            <option value="Registration" <c:if test="${status.value == 'Registration'}"> selected="true"</c:if>>Registration</option>
                            <option value="Performance" <c:if test="${status.value == 'Performance'}"> selected="true"</c:if>>Performance</option>
                            <option value="Other" <c:if test="${status.value == 'Other'}"> selected="true"</c:if> id="otherSelect">Other</option>
                        </select>

<textarea name="otherProblemText" id="otherProblemText" class="textarea_longest_half" disabled="true">${status.value}</textarea>
I'd appreciate any help that you can offer.

Thanks,