<html>
<head>
<title>dynamic style</title>
<script type="text/javascript" >
var helpers=["your name must be in the form:first name middle initial last name",
"your email address must have the form:user domine",
"your user ID must have atleast 6 charecters",
"your password must have atlest 6 characters and it must include one digit",
"this box provides advice on filling out the form on this page, put the mouse cursor over any input field to get advice"];
function message(advicenumber)
{
document.getElementById("advicebox").value=helpers[advicenumber];
}
</script>
</head>
<body>
<form action="">
<p>
Name:<input type="text" onmouseover="message(0)" onmouseout="message(4)"/>
<br/>
email:<input type="text"onmouseover="message(1)"onmouseout="message(4)"/>
<br/><br/>
to create an account provide the following:<br/>
UserID:<input type="text"onmouseover="message(2)"onmouseout="message(4)"/>
<br/>
password:<input type="password"onmouseover="message(3)"onmouseout="message(4)"/>
<br/>
<textarea id="advicebox" rows="3" cols="40"></textarea>
</body>
</html>
No comments:
Post a Comment