1、引入插件JS
<script type="text/javascript" src="PDFobject.js"></script>
2、调用方法
<script> window.onload = function (){ var success = new PDFObject({ url: "test.pdf"}).embed("pdf"); }; </script>
3、插件div显示
<div id="pdf" style="height: 100%"></div>
效果:
时间: 2024-10-13 17:56:00