Does IE10 support FormData()?

匿名 (未验证) 提交于 2019-12-03 08:44:33

问题:

I've read (here) that IE10 supports FormData(). But when I type this into the IE10 JavaScript console:

foo = new FormData(); 

I get the error, "FormData not defined"

Does IE10 support FormData() or doesn't it? Is there a trick to getting it to work in IE10?

回答1:

I can confirm that it does - running your code in the console on this page works fine.

I will therefore hypothesize that you are in Quirks Mode, and therefore the browser is pretending it doesn't know it to be compatible with said Mode.

Make sure your page has a valid <!DOCTYPE html> at the start and no errors to fall back into quirks mode.



回答2:

Also make sure your webserver request "edge" compatibility mode. That may help preventing fallback to older compatibility modes.



标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!