Welcome to WebmasterWorld Guest from 54.167.76.176

Forum Moderators: incrediBILL

Message Too Old, No Replies

Why do Firefox textareas not wrap as they should

     

midi25

10:12 pm on Mar 16, 2005 (gmt 0)

10+ Year Member



Hi I have tried placing a textarea on my page. Its works fine in IE. But when in FF the text dosnt wrap and it just continues to scroll on and on and on.

How can I get around this? Do you still suffer the same problems?

tedster

4:14 am on Mar 17, 2005 (gmt 0)

WebmasterWorld Senior Member tedster is a WebmasterWorld Top Contributor of All Time 10+ Year Member



I have not noticed or heard of any problem in this area. Are you using cols= and rows= attributes, and is the textarea within a <form> element?

midi25

10:01 am on Mar 17, 2005 (gmt 0)

10+ Year Member



Yes. If you look at html school on the w3c and then look up the textarea element in the html ref link. They have an example. View it in IE and then view it in Firefox and you will see what I mean.

IE wraps the text while firefox just continues scroll to infinity.

Wish I could post the link.

Thanks

dcrombie

11:56 am on Mar 17, 2005 (gmt 0)

10+ Year Member



Wraps fine in FireFox (Mac).

It used to be that Netscape required 'wrap="virtual"' as an attribute on the textarea to enable wrapping, but AFAIK that's no longer necessary.

I have one client (out of dozens) who has the same problem in Explorer, so it may be a problem in Windoze rather than the browsers.

midi25

3:32 pm on Mar 17, 2005 (gmt 0)

10+ Year Member



I am not imagining this.

Can someone please check

<textarea> in FireFox

I have tried it on four different windows machines now. And I am getting the same problem.

IE wraps inner text which is fine. But FF just continues to scroll the text horizontally.

Is this a bug in FF?

Thanks

tedster

5:31 pm on Mar 17, 2005 (gmt 0)

WebmasterWorld Senior Member tedster is a WebmasterWorld Top Contributor of All Time 10+ Year Member



look at html school on the w3c and then look up the textarea element in the html ref link.

We do allow links to authoritative resources, such as w3schools.org. Is this the page you are refering to?

[w3schools.com...]

If so, it displays fine in my FireFox browser: FF 1.01 on WinXP SP2

midi25

8:46 pm on Mar 17, 2005 (gmt 0)

10+ Year Member



Yes that is the page. Its displays ok. But try entering some data and go past the visible content. Instead of wrapping as it should. It just continues to scroll.

Meaning that to get line breaks the user will have to manually press the enter key on the keyboard. This behaviour is no needed in IE as one you reach the end the text it wrapped.

iamlost

9:10 pm on Mar 17, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



From w3schools source code:

<textarea rows="2" cols="30">The cat was playing in the garden. Suddenly a dog showed up.....</textarea>

The answer is the number of rows. In their example they have limited rows to "2". Change the number of rows and the behaviour will change.

tedster

9:16 pm on Mar 17, 2005 (gmt 0)

WebmasterWorld Senior Member tedster is a WebmasterWorld Top Contributor of All Time 10+ Year Member



Meaning that to get line breaks the user will have to manually press the enter key on the keyboard.

Midi, I get word wrap as needed and a vertical scrollbars as soon as the content requires it - no need for manual enter key returns.

Not sure what you are seeing but I don't think my computer is showing the same thing as yours. The behavior looks the same in IE and Firefox.

midi25

8:59 am on Mar 18, 2005 (gmt 0)

10+ Year Member



Strange as I have tested this on multiple pcs now and get the same behaviour.

If I type

aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa

in the textarea. IE will wrap this. FF will just scroll horizontally and keep it all on one line.

Its should work the same as IE but it dosnt.

tedster

9:31 am on Mar 18, 2005 (gmt 0)

WebmasterWorld Senior Member tedster is a WebmasterWorld Top Contributor of All Time 10+ Year Member



Yes - I understand what you are saying. I do not see this behavior on the three systems I have checked, and no one else so far has reported seeing it. We have a lot of FireFox users here. All are welcome to check the W3Schools page listed above to check. I think we'll hear from someone else if they see it - then maybe that will help pin it down a bit more.

To be honest, word wrap in a textarea is such a basic browser function, I would be very surprised if it was a widespread failure of FF. There's some other reason you're seeing it besides a bug in the browser - some other combination of who knows what factors.

benihana

9:40 am on Mar 18, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



im seeing the same thing when entering long strings with no spaces, on all text areas in FF only. (including this box im typing in now)

FF 1 / win XP

extentions: web dev T/B, SEOpen, checky

skin: #*$!zilla

not that I often enter long strings with no spaces, though...

<added>that is to say, its not a word wrap issue, more of a word break issue</added>

tedster

9:34 am on Mar 19, 2005 (gmt 0)

WebmasterWorld Senior Member tedster is a WebmasterWorld Top Contributor of All Time 10+ Year Member



I see it now - I get a natural line break the first time one is needed, but if the unbroken character string continues and there needs to be a second line break, that doesn't happen and then the side-scroll starts.

That is a bug, I'd say. Has anyone found a work-around?

wickydoodah

6:27 pm on Mar 19, 2005 (gmt 0)

10+ Year Member



My memory is a little hazy this morning, but I think if you add wrap="hard" to the text area tag it will force all text to stay within the defined box (no horizontal scroll). A client of mine had a guestbook on their site and some goof ball would keep posting a l-o-n-g string of continuous text just to break the page layout. Seems to me that after adding wrap="hard" to the text area box it forced the text to always break even if no spaces were entered.

Don't know how Firefox will handle it, but you might give it a try.

dmmh

1:06 pm on Mar 20, 2005 (gmt 0)

10+ Year Member



Ive been bugged about this too, but I stopped caring :)

MatthewHSE

5:05 pm on Mar 21, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



If I'm understanding correctly, I've seen this. FireFox will add horizontal scrollbars to a textarea if the number of consecutive characters unbroken by a space exceeds the width of the textarea. Enter a space, and wrapping will continue as normal.

I always considered it a bug in IE that it would break an unbroken text string. Looking at it now, I wouldn't call either behavior a bug; just different.

bartainer

3:55 pm on Mar 25, 2005 (gmt 0)

10+ Year Member



I do hope this is what everyone is talking about!

My web master tutor (computer science degree) has detected the problem and did contact Mozzila. What seems to happen is that text is pushed, e.g. when entering info into a field, the text pushes the text box. Furthermore, the horizontal scroll bar will increase in size because the text pushes. Very weird! It is to my understanding; the makers of Firefox are working on this bug! Nice catch.

Ron

Purple Martin

1:59 am on Mar 29, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



If I type

aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa

in the textarea. IE will wrap this. FF will just scroll horizontally and keep it all on one line.


That's what I see too.

Its should work the same as IE but it dosnt.

:) Browsers don't have to be all the same: it's entirely up to the browser makers. Text-wrapping behaviour is something that I've had problems with before: somtimes I wish a browser would behave one way, sometimes I wish the same browser would behave the other way, depending on the situation. There is no "right" or "wrong" for this one.
 

Featured Threads

Hot Threads This Week

Hot Threads This Month