I have a textbox. I wanted to use a JS onclick to append the input in the textbox to the "btnGO" button as below but it's not working:
document.getElementById('btnGo').onclick = function() {
var search = document.getElementById('dlrNum').value;
window.location.url = "http://consumerlending/app/indirect/dealerComments.aspx?dlrNum=" + search;
}
<input id="dlrNum" type="text" name="dlrNum" autocompletetype="disabled" class="ui-autocomplete-input" autocomplete="off">
<input id="btnGo" type="submit" value="GO" name="GO" runat="server">
What could I be missing?
onloadlistener; b)window.location.assign(URL)<body>section.