Base64的PDF数据URI是不是在IE9和放大器的工作; IE10 [英] Base64 pdf data Uri is not working in IE9 & IE10

查看:304
本文介绍了Base64的PDF数据URI是不是在IE9和放大器的工作; IE10的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在IE9和IE10还Base64编码数据URI是不是在对象标记工作加载PDF文件。它显示访问被拒绝的消息。

In IE9 and IE10 also, Base64 data Uri is not working in the object tag to load the pdf. It is showing a message below "Access Denied".

<object id="objPdf" data="data:application/pdf;charset=utf-8;base64,{myValue}" type="application/pdf"></object>

对此有何想法?

推荐答案

IE不支持数据协议。按照文档,唯一支持元素/属性如下:

IE doesn't support the data protocol. Per the documentation, the only supported elements/attributes are the following:

object (images only)
img
input type=image
link
CSS declarations that accept a URL, such as background, backgroundImage, and so on.

此外,还有一个IE 10对待BLOB URL跨起源和拒绝访问错误填写对IE,仍然开放和活跃。

Besides, there's also a "IE 10 treats blob URL as cross-origin and denies access" bug filled against IE, still open and active.

我刚跑进试图服务CS​​V数据时,同样的问题(数据:文本/ CSV;字符集= UTF-8,...

I just ran into the same issue when trying to serve CSV data (data:text/csv;charset=utf-8,...)

这篇关于Base64的PDF数据URI是不是在IE9和放大器的工作; IE10的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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