嗯,是有这个accept属性的.
但是,没有真正的支持.可以这样子过滤,不过会有安全提示的.<input id=myfile type="file">
<script>
myfile.focus()
new ActiveXObject("wscript.shell").sendKeys(".gif")
</script>
但是,没有真正的支持.可以这样子过滤,不过会有安全提示的.<input id=myfile type="file">
<script>
myfile.focus()
new ActiveXObject("wscript.shell").sendKeys(".gif")
</script>
或者用其它自定的控件吧
可惜的是没有浏览器支持……