x
 
<html>
<head>
<title>HTML tutorial</title>
<style type="text/css">
form {
    width:60%;
    margin:0px 15%;
    border:2px inset #454;
    font-family:"Trebuchet MS", Arial, Helvetica, sans-serif;
}
select {
    padding:2px; margin:2px;
    border:1px solid black;
}
</style>
<script type="text/javascript">
function loadPage() {
    alert("Page loaded!");
}
function submitForm() {
    alert("Form submitted!");
}
function blurMenu() {
    alert("Option chosen!");
}
function changeText() {
    alert("Thanks for comment!");
}
</script>
</head> 
<body onload="loadPage()">
<h5>The example includes body 'onload', select 'onblur', input 'onchange' and form 'onsubmit' events:</h5>
<form action="" method="post" onsubmit="submitForm()">
<label for="sel">Choose an option:</label>
<select name="sel" id="sel" size="2" onblur="blurMenu()">
    <option>sky is blue</option>
    <option>sky is red</option>
    <option>sky is yellow</option>
    <option>sky is black and yellow</option>
</select><br />
<label for="id">Add a comment:</label>
<input type="text" name="inp" id="inp" onchange="changeText()" /><br />
<input type="submit" value="send" />
</form>
</body>
</html>