html - Textarea overflow:auto difference in height -


following code renders textarea should have 3 visible rows:

<textarea id="txtinput" rows="3" cols="20" style="overflow:auto"></textarea> 

however, in firefox (version 20.0.1), 4 rows shown instead of 3.

see http://jsfiddle.net/kxxss/

how can fix this?

firefox adds lines after textfields. can fix css :

@-moz-document url-prefix() {     textarea {         height: 4em;     } } 

the @-moz...is mozilla specific rule, url-prefix rule applies rule page url starts it.


Comments

Popular posts from this blog

user interface - Python attempting to create a simple gui, getting "AttributeError: 'MainMenu' object has no attribute 'intro_screen'" -

jquery - Common JavaScript snippet to share files on Google Drive, Dropbox, Box.net or SkyDrive -

Android Gson.fromJson error -