如何禁用多行输入用户动态地调整? [英] How to disable multiline input being dynamically resized by user?
问题描述
我有我的HTML表单和一些浏览器(Firefox 4和Chrome)上的多行文本输入允许用户动态地调整其大小。这是好的,但它打破我的布局。是否有可能禁用此功能?
I have a multiline input on my html form and some browsers (firefox 4 and chrome) allow users to resize it dynamically. It is nice, but it breaks my layout. Is it possible to disable this feature?
感谢
推荐答案
如果用户调整领域,这可能是因为他们想要的(或需要)的它更大 1 。
If users resize the field, it's probably because they want (or need) it to be bigger 1.
在这种情况下,你应该考虑你的用户知道他们在做什么,这样做是因为他们想/需要,他们将接受布局是一个小的破的,提供它允许他们使用该文本区域。
In such a case, you should consider your users know what they are doing, are doing it because they want / need to, and that they will accept the layout to be a little broken, provided it allows them to use that textarea.
结果
不过,如果你想这样做的(你不应该)的,引用的如何禁用textarea的大小调整:
textarea {
resize: none;
}
结果
1 <子>我没有看得很清楚,当我放大,或使一些的大的,那是因为我需要太多 - 而且,在这种情况下我preFER的布局有点打破,一个网站,我不能用!
1. I don't see very well, and when I zoom, or make something bigger, it's because I need too -- and, in such a case, I prefer a layout a bit broken to a website I cannot use !
这篇关于如何禁用多行输入用户动态地调整?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!