<!DOCTYPE html>
<html>
<body>
<form action="https://www.w3schools.com/action_page.php">
A hidden field:<input type="hidden" id="myInput" name="country" value="Norway"><br>
<input type="submit" value="Submit">
</form>
<p>Notice that the hidden field above is not shown to a user.</p>
<p>Submit the form to see the value of the name and value attribute of the hidden input field, as received input.</p>
<p>Click the "Try it" button to change the value from "Norway" to "USA".</p>
<button onclick="myFunction()">Try it</button>
<p id="demo"></p>
<script>
function myFunction() {
document.getElementById("myInput").value = "USA";
document.getElementById("demo").innerHTML = "The value of the value attribute was changed. Try to submit the form again.";
}
</script>
</body>
</html>