Attribute: Size

The size attribute specifies the size (in characters) for the input field:

HTML file: Displayed by browser:
<form>
First name:
<br /><input type="text" name="firstname" value="John" size="40">
<br />
<br />Last name:
<br /><input type="text" name="lastname">
</form>
First name:


Last name:

Back button Table of Contents Next button