document.getElementById('send-data').addEventListener('click',buttonFunction)
function buttonFunction(){
let enteredValue = document.getElementById('entered_value').value
let enteredValue2 = document.getElementById('entered_valuetwo').value
let selectValue = document.getElementById('selected_value').value
console.log(enteredValue,enteredValue2,selectValue)
}
just add this to your js
document.getElementById('send-data').addEventListener('click',buttonFunction) function buttonFunction(){ let enteredValue = document.getElementById('entered_value').value let enteredValue2 = document.getElementById('entered_valuetwo').value let selectValue = document.getElementById('selected_value').value console.log(enteredValue,enteredValue2,selectValue) }