17 lines
328 B
HTML
17 lines
328 B
HTML
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<title>Input Field and Button</title>
|
|
</head>
|
|
<body>
|
|
<input type="text" id="myInput">
|
|
<button type="button" onclick="myFunction()">Submit</button>
|
|
<script>
|
|
function myFunction() {
|
|
var input = document.getElementById("myInput").value;
|
|
alert("Input value: " + input);
|
|
}
|
|
</script>
|
|
</body>
|
|
</html>
|