如何给input[file]定义cursor
来源:http://stackoverflow.com/questions/1537223/change-cursor-type-on-input-type-file
Simple question... How do I change the cursor type on a file input type?
I've tried the following:
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
- <html>
- <head>
- <style>
- input[type="file"] {
- cursor: pointer;
- }
- </style>
- </head>
- <body>
- <input type="file">
- </body>
- </html>
For some reason, it won't play ball.
--------------以下是回复----------------------------
It works differently in different browsers. I guess it's because the file input type is quite special.
What browser/version do you use?
I know that IE6 does not support to specify the type in the style.
How it works in the different browsers
IE7+
Works perfectly
FireFox
Does not work at all.
Chrome and Safari (identical behavior)
Uses arrow over the button, but your defined cursor over the rest.
Opera
Uses your defined cursor when entering any part from outside the input element, but the default cursor is used when moving mouse internally between text field and button (text cursor over the text field, and arrow over the button).
如何给input[file]定义cursor的更多相关文章
- chrome 下 input[file] 元素cursor设置pointer不生效的解决
https://jingyan.baidu.com/article/48b558e32fabb67f38c09a81.html 环境是chrome浏览器,今天发现为html网页中的input [fil ...
- 自定义input file样式
自定义input file样式:一般都是通过隐藏input,通过定义label来实现.这种做法要注意的是label的for属性要指定input对应的id; <!DOCTYPE html> ...
- 编译安装mmseg提示cannot find input file: src/Makefile.in错误
今天安装中文词检索功能模块 coreseek,其中一个分词模块 mmseg ,编译安装到最后,出现annot find input file: src/Makefile.in aclocal // ...
- 从重置input file标签中看jQuery的 .val() 和 .attr(“value”) 区别
背景: 在清空input file标签选中值时,分别用了以下方法,发现有的对有的错: [√]$("#file")[0].value = ""; [√]$(&qu ...
- Nginx执行php显示no input file specified的处理方法
/var/www/nginx-default中放上一份phpinfo.php,使用http://localhost/phpinfo.info 访问,结果报错,显示 “No input file spe ...
- html input file标签的上传文件 注意点
文件上传框 代码格式:<input type=“file” name=“...” size=“15” input enctype="multipart/form-data“ maxl ...
- ajax+ashx 完美实现input file上传文件
1.input file 样式不能满足需求 <input type="file" value="浏览" /> IE8效果图: Firefox效 ...
- input file 在开发中遇到的问题 类似ajax form表单提交 input file中的文件
最近在做项目的过程中遇到个问题,在这里做个记录防止日后忘记 现今的主流浏览器由于ajax提交form表单无法把文件类型数据提交到后台,供后台处理,可是开发中由于某些原因又不得不用ajax提交文件, 为 ...
- ajax form表单提交 input file中的文件
ajax form表单提交 input file中的文件 现今的主流浏览器由于ajax提交form表单无法把文件类型数据提交到后台,供后台处理,可是开发中由于某些原因又不得不用ajax提交文件, 为了 ...
随机推荐
- 【DIOCP知识库】连接上下文TIocpClientContext
来自弦子介绍 [概述] 该类管理远程连接,每一个远程连接会对应一个该类的实例,开发时可以通过继承该类,扩展属性,可以存储更多的连接信息,可以重写OnRecvBuffer方法进行数据逻辑的处理 [字段/ ...
- Keynote of Python III
[Keynote of Python III] 1.许多大型网站是用Python开发的,例如YouTube.Instagram,还有国内的豆瓣.很多大公司,包括Google.Yahoo等,甚至NASA ...
- delphi之多线程编程
本文的内容取自网络,并重新加以整理,在此留存仅仅是方便自己学习和查阅.所有代码均亲自测试 delphi7下测试有效.图片均为自己制作. 多线程应该是编程工作者的基础技能, 但这个基础我从来没学过,所以 ...
- 使用C# WinForm窗体制作经理评分项目 ——S2 2.2
在窗口加载时初始化三个员工对象 用数组存放 这是员工类的大致字段和属性. 在FrmMain中给对象数组附初值 以上 FrmMain中用一个ListView控件展示员工信息,通过以上代码将对象数组中的内 ...
- 请不要做浮躁的IT人
1.不要看到别人的回复第一句话就说:给个代码吧!你应该想想为什么.当你自己想出来再参考别人的提示,你就知道自己和别人思路的差异. 2.初学者请不要看太多太多的书那会误人子弟的,先找本系统的学,很多人用 ...
- AngularJS学习--- 过滤器(filter),格式化要显示的数据 step 9
1.切换目录,启动项目 git checkout step- npm start 2.需求: 格式化要显示的数据. 比如要将true-->yes,false-->no,这样相互替换. 3. ...
- 模板(Template)
最近阅读google chromium base container stack_container代码,深刻感觉到基础知识不扎实. // Casts the buffer in its right ...
- redis 内存泄露
http://www.oschina.net/question/2266476_246221 http://stackoverflow.com/questions/24304212/how-to-de ...
- as 和 is 区别
as 将对象转换某类型,如果失败则返回null.is用来判断对象是否为某个类型,在判断过程中会对对象进行两次转换,而as只有一次转换,故as效率高.
- Linux下一些文件夹的含义
在 Linux系统里面,"分区",被称作"挂载点",简单明了的说,"挂载点"意思就是:把一部分硬盘容量,"分"成一个文件 ...