2017-09-25 132 views
1

我使用IDR工具(https://www.idrsolutions.com/online-pdf-to-html5-converter)将PDF文件转换为HTML5。它具有呈现svg文件的对象标签。如SVG not showing in object tag after publishing to web所述,我在应用程序的web.config文件或IIS服务器中添加了'.svg'mime类型。它仍然没有工作。我试图用img标记和数据属性替换object标记与src属性。然后它导致空的UI页面。此外,我尝试使用iframe标签,但会导致UI失真。有没有其他方法可以解决这个问题?使用img标签替换对象标签UI变空白

的代码行是如下:

<div id="pg1" style="-webkit-user-select: none;"><object width="935" height="1210" data="1/1.svg" type="image/svg+xml" id="pdf1" style="width:935px; height:1210px; background-color:white; -moz-transform:scale(1); z-index: 0;"></object></div> 

回答