Textarea scrollbar

JavaScript and client side scripting.

Moderator: General Moderators

Post Reply
User avatar
highjo
Forum Contributor
Posts: 118
Joined: Tue Oct 24, 2006 1:07 pm

Textarea scrollbar

Post by highjo »

Hi! propbably i shouldn't be asking this tips but i' don't know why what seems obviuos to me is not working.
I just want my textarea not to have an horizontal scrollbar.The wrap attribute was the obvious option for me and is not doing it.So i just want to ask how do you guys do that.A typical examle is this textarea where i'm typing this message.it doesn't have an horizontal scrollbar.Please let me know thank you
User avatar
vargadanis
Forum Contributor
Posts: 158
Joined: Sun Jun 01, 2008 3:48 am
Contact:

Re: Textarea scrollbar

Post by vargadanis »

Set the "cols" attribute of the textarea to XY. It will do it unless MS IE. For that u need to do CSS: overflow-x:hidden;

Code: Select all

<textarea style="overflow-x: hidden;"></textarea>
User avatar
highjo
Forum Contributor
Posts: 118
Joined: Tue Oct 24, 2006 1:07 pm

Re: Textarea scrollbar

Post by highjo »

thankis man.You mean something like this cols = "XY"?
User avatar
vargadanis
Forum Contributor
Posts: 158
Joined: Sun Jun 01, 2008 3:48 am
Contact:

Re: Textarea scrollbar

Post by vargadanis »

highjo wrote:thankis man.You mean something like this cols = "XY"?
Yup... In the future, if you have this sort of questions, you will find an answer here: http://www.w3schools.com/
Post Reply