I am new for this type of functionality, how can i retrieve the textbox values and that every value appending to the beside select box option after clicking on add button Any One please give me a suggestion to fixed it.
$(document).ready(function(){
var val = $('#txt-val').val();
var selectval = $('#newval').val();
$('#addbtn').click(function(){
//who to retrive textbox value and append as a option value of select box .
});
});
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<input type="text" style="width:150px;" id="txt-val" />
<button id="addbtn">Add</button>
<select id="newval" style="width:150px;">
<option></option>
</select>