HTML and CSS Reference
In-Depth Information
Figure 11.26 The textbox and its properties.
EXAMPLE 11.18
<html>
<head>
<title>Assigning Value on the Fly to a Text Field</title>
</head>
<body bgcolor="aquamarine">
<font face=arial>
<big>
1
<form name="form1" id="form1">
Enter your name
2
<input type="text"
3
name="yourname"
id="yourname"
size="60"/>
<p></p>
Click in the box
4
<input type="text"
5
name="message"
id="message"
size="60"
6
onClick="this.value='Greetings and Salutations, '+
document.forms[ " form1 " ][ " yourname " ].value+ '!';"
/>
<p>
<input type="reset" />
</p>
7
</ form>
</big></font>
</body>
</html
Search WWH ::




Custom Search