我知道这个问题被问过很多次,我在问之前在这里做了研究,
我得到了这样的 html,
<div id="camerathumbnail">
<input type="file" id="thumbUpload" onchange="fileSelectHandler('module','false')" accept="image/gif, image/jpeg,image/jpg,image/bmp,image/pjpeg,image/png">
</div>
和像这样的 css 类:
#camerathumbnail {
width: auto;
height: auto;
position: absolute;
visibility: hidden;
margin-top: -5px;
margin-left: 87px;
padding: 2px;
border: 1px solid #d7d7d7;
background: url(/Images/Camera_import_24.png) no-repeat center;
background-color: #fff;
cursor: pointer
}
#thumbUpload {
position: relative;
z-index: 2;
width: 24px;
height: 24px;
opacity: 0;
cursor: pointer;
margin: 0;
background: #fff;
}
使用这个 css,我看不到手形图标,我真的想要这个 div 上的手形图标,由于输入 type=file
,我看不到手形图标,
请提供最简单的修复方法,我肯定不会使用旧浏览器
最佳答案
您可以随时使用 attribute selector :
input[type='file'] {
cursor: pointer;
}
<input type="file" />
关于jquery - 输入类型 ="file"上的手形光标,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/26998775/