Remove scrollbars from textarea

做~自己de王妃 提交于 2019-11-28 05:10:02
tinthetub

Try the following, not sure which will work for all browsers or the browser you are working with, but it would be best to try all:

<textarea style="overflow:auto"></textarea>

Or

<textarea style="overflow:hidden"></textarea>

...As suggested above

You can also try adding this, I never used it before, just saw it posted on a site today:

<textarea style="resize:none"></textarea>

This last option would remove the ability to resize the textarea. You can find more information on the CSS resize property here

Dinder Logic

style="overflow: hidden" and style="resize: none" were the ones that did the trick.

For MS IE 10 you'll probably find you need to do the following:

-ms-overflow-style: none

See the following:

https://msdn.microsoft.com/en-us/library/hh771902(v=vs.85).aspx

Give a class for eg: scroll to the textarea tag. And in the css add this property -

.scroll::-webkit-scrollbar {
   display: none;
 }

It worked for without missing the scroll part

I was able to get rid of my scroll bar on the body of text by removing my max-height attribute of my class.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!