HTML5 Add Mobile Touch Web version PDF file Viewer Plugin Tutorial

Source: Internet
Author: User

I. Methods of Use
<script type= "Text/javascript" src= "Jquery.min.js" ></script>
<script type= "Text/javascript" src= "Pdf.compatibility.js" ></script>
<script type= "Text/javascript" src= "Pdf.js" ></script>
<script type= "Text/javascript" src= "Jquery.touchSwipe.js" ></script>
<script type= "Text/javascript" src= "Jquery.panzoom.js" ></script>
<script type= "Text/javascript" src= "Jquery.mousewheel.js" ></script>
<script type= "Text/javascript" src= "Jquery.touchPDF.js" ></script>
<link href= "Jquery.touchPDF.css" rel= "stylesheet" media= "screen"/>

Second, HTML structure
<div id= "Mypdf" ></div>

Third, initialize the plug-in
<script type= "Text/javascript" >
$ (function () {
$ ("#myPDF"). PDF ({source: "Yourfile.pdf"});
});
</script>

You can also add some colorful tabs bookmarks to the PDF page.
$ (function () {
$ ("#myPDF"). PDF ({
Source: "Demo.pdf",
tabs:[
{title: "Tab 1", Page:2, Color: "Orange"},
{title: "Tab 2", Page:3, Color: "Green"},
{title: "Tab 3", Page:5, Color: "Blue"},
]
});
});

Keymob Mobile Advertising Platform is a professional mobile application advertising management tools, the use of keymob can be smoothly through the application market audit, but also can not worry about the number, and can easily switch with any platform, which greatly improve the fill rate, thereby achieving higher revenue.

HTML5 Add Mobile Touch Web version PDF file Viewer Plugin Tutorial

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.