即使PC上没有安装adobe,我们如何在IE浏览器上显示PDF [英] How can we display PDF on IE browser even if adobe was not installed on PC
问题描述
我正在尝试在浏览器上显示PDF,但如果在IE中的ADD ons中禁用Adobe(或者用户未在其PC上安装Adobe),则不会显示该PDF。我不想强迫用户下载PDF来查看我的网站的PDF。我需要编写一个与3种浏览器兼容的解决方案:IE,Firefox和chrome。以下是我的简单代码:
I am trying to display a PDF on browser but it is not shown if Adobe was disabled in ADD ons in IE (or when user has not installed Adobe on his PC). I don't want to force users to download PDF to view the PDF of my website. I need to write a solution compatible with the 3 browsers: IE, Firefox and chrome. Below is my simple code:
<embed src="..\UserGuide.pdf" width="740" height="500">
有什么想法吗?
我尝试过:
我在网上搜索,我发现了一些关于pdf.js的内容,而且我很喜欢它。但我不知道如何在我的代码中使用它而不是嵌入标签,任何帮助?
Any idea ?
What I have tried:
I was searching online and I found something about pdf.js and I am very interesed in it. but I don't know how to use it in my code instead of embed tags, any helps?
推荐答案
如果用户没有PDF查看器机器他们无法查看PDF文件。如果您没有Word查看器,则无法查看Word文件,如果您没有文本文件查看器,则无法查看文本文件,如果您没有Access数据库查看器,则大致相同无法查看Access数据库。 PDF文件没有什么特别之处,它是一种需要特定查看器的专有格式。
If the user doesn't have a PDF viewer on their machine they can't view PDF files. Much the same way if you don't have a Word viewer you can't view Word files, if you don't have a text file viewer you can't vie text files, if you don't have an Access database viewer you can't view Access databases. There is nothing special about PDF files, it is a proprietary format that needs a specific viewer.
这篇关于即使PC上没有安装adobe,我们如何在IE浏览器上显示PDF的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!