Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

maxlength related to size? 1

Status
Not open for further replies.

LaundroMat

Programmer
Dec 2, 2003
67
BE
I think I'm becoming stupid, because I just know what I'm about to ask is easy to solve.

(test code from
Code:
<html>
<body>
<form>
First name: 
<input type=&quot;text&quot; name=&quot;firstname&quot; size=&quot;10&quot; maxlength=&quot;20&quot;/>
<br />
Last name: 
<input type=&quot;text&quot; name=&quot;lastname&quot; size=&quot;20&quot; />
</form>
</body>
</html>

Why, oh why can't I type in more than 10 characters in the first input field?
 

You can.

The code you gave works fine in IE, NN, Opera, and Mozilla.

Are you typing in different characters? If you're not, and you're using a test string like &quot;11111111111111111111&quot;, then you may not realise that you've got more than 10, as when it scrolls to the left, you wouldn't notice it.

Try typing in &quot;123456789012345&quot; and you should see it work.

Hope this helps!

Dan
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top