Html 禁止游标?
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/5904865/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Forbidden cursor?
提问by Hailwood
I am looking for the name of the "forbidden/cancel" cursor.
我正在寻找“禁止/取消”光标的名称。
I can't seem to find it.
我好像找不到
回答by BoltClock
The values of cursor
that represent what you're looking for are not-allowed
and no-drop
. These values are new to CSS3, so if you need browser compatibility you should specify an image instead.
的值cursor
代表您要查找的内容是not-allowed
和no-drop
。这些值是 CSS3 的新值,因此如果您需要浏览器兼容性,则应改为指定图像。
回答by Leopold Gault
The css cursor: not-allowed;
also works.
css cursor: not-allowed;
也有效。
回答by Alireza Sabahi
here is complete sample:
这是完整的示例:
.not-allowed {
cursor: not-allowed;
}
<input type="submit" value="not-allowed" class="not-allowed" disabled />