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 Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

No Horizontal Scrolling in <Textarea>

Status
Not open for further replies.

gwillr

IS-IT--Management
Nov 4, 2003
267
CA
I have an input <textarea> where the user can enter a blurb and submit. I am trying to disable any horizontal scroll. it works in IE with style="overflow:hidden"

But in Mozilla, the text will not wrap, and as soon as the input exceeds the width of the textarea, the scrollbar appears.

Is there any way, in either css or html to correct this with mozilla?

Gary

 
As long as your users are typing in stuff without any breaks then you can't do anything except what you're doing right now. Mozilla should however ignore any text that goes beyond the width of the textarea and make it invisible with that attribute. IE has some break-word attribute which will break the long words and make them wrap, but nothing as such exists in Mozilla. Sorry.
 
Thanks for the response.

After my posting, I had done some more research on the <textarea> and some more testing as well.

I have found that the way in which Mozilla and ID displays them is in fact quite different.

The differnece you describe is one of the main ones, but others include the sizing of the textarea. Mozilla displays them quite a lot larger than IE, giving potential to layout issues.

Afterward, I just decided to scrap the textarea and just use a regular text input form.

Gary

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top