IE8导致FILE输入条目通过SendKeys空白 [英] IE8 causing FILE input entry to be blank via SendKeys

查看:240
本文介绍了IE8导致FILE输入条目通过SendKeys空白的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

:应用程序:HTA(因此IE)这是一个使用SendKeys来填充FILE输入字段的应用程序。


$ b 问题:永远不会上传文件。


$ b 描述:离屏形式(用户不可见)将文件上传到服务器。文件输入是通过SendKeys(javascript)输入的。 IE8安装时似乎被隔离。






有谁知道可能是什么原因导致了这个问题以及所有解决方法?

对不起,缺乏信息。如果没有提交答案,我会编辑附加信息的问题。 类型= 文件 >元素设置为只读,以防止安全攻击。 (请参阅文章)。



因此编程方式是不可能的。


Application: HTA (therefore IE) This is an application that uses SendKeys to populate a FILE input field.

Issue: File is never uploaded.

Description: An offscreen form (invisible to user) uploads a file to the server. The file input is entered via SendKeys (javascript). Appears to be isolated to when IE8 is installed.


Does anyone know of what may be causing this and any workarounds?

Sorry for lack of information. I will edit the question with additional information if no answers are submitted.

解决方案

IE8 has set the <input type="file"> element to read-only in order to prevent security attacks. (see article).

Therefore a programmatic way isn't possible.

这篇关于IE8导致FILE输入条目通过SendKeys空白的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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