无论如何删除“没有选择的文件”从类型=文件输入? [英] anyway to remove "no file selected" from type=file inputs?

查看:87
本文介绍了无论如何删除“没有选择的文件”从类型=文件输入?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



无论如何,我似乎都无法解决在输入文件旁边显示的No file selected文本。 >你们知道任何方式吗?

解决方案

没有跨浏览器的方式来做到这一点。 no file selected文本位于widget的实现定义部分,我不相信大多数浏览器提供的浏览器特定定制方式都很多。另一方面,当value属性为空时,您可以简单地使用CSS来覆盖文本。


I can't seem to figure out anyway to remove the "No file selected" text that shows up next to my inputs with the type="file".

Do you guys know any way?

解决方案

There is no cross-browser way to do this. The "no file selected" text is in the implementation-defined part of the widget, and I don't believe that most browsers offer much in the way of browser-specific customization. On the other hand, you could simply use CSS to cover the text with something when the value attribute is empty.

这篇关于无论如何删除“没有选择的文件”从类型=文件输入?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆