I'm having this problem where I can't seem to figure out how to show my (filled in) form in a jquery alert. Under my code is a standard form in HTML nothing wrong there all id
's are named what you can see in the .val()
.
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<script>
$(document).ready(function() {
var name = $("#name").val();
console.log(name);
$('#form').submit(function() {
$('#progress').show();
alert (" Formulier: " + $("#form input").val(name, email, number, comment));
});
});
</script>
<style>
#progress {
display: none;
color: green;
}
</style>