1,319
questions
97
votes
2
answers
186k
views
How to Use pdf.js [closed]
I am considering using pdf.js (an open source tool that allows embedding of a pdf in a webpage). There isn't any documentation on how to use it.
I assume what I do is make an html page with the ...
85
votes
3
answers
183k
views
Pdf.js: rendering a pdf file using a base64 file source instead of url
I'm trying to render a page from a pdf with pdf.js
Normally, using a url, I can do this:
PDFJS.getDocument("http://www.server.com/file.pdf").then(function getPdfHelloWorld(pdf) {
//
// Fetch the ...
66
votes
11
answers
115k
views
How to display whole PDF (not only one page) with PDF.JS?
I've created this demo:
http://polishwords.com.pl/dev/pdfjs/test.html
It displays one page. I would like to display all pages. One below another, or place some buttons to change page or even better ...
52
votes
2
answers
128k
views
Extract text from pdf file using javascript [duplicate]
I want to extract text from pdf file using only Javascript in the client side without using the server. I've already found a javascript code in the following link: extract text from pdf in Javascript
...
44
votes
1
answer
62k
views
Edit *existing* PDF in a browser [closed]
I have a web application that is currently getting a base64 representation of a PDF from the server. I'm able to use Mozilla's pdf.js to display this on a <canvas> and toggle through the pages ...
43
votes
3
answers
73k
views
PDF.js scale PDF on fixed width
I have a fixed box where I want to display my PDF's in rendered by PDF.js. As PDF.js documentation is not really accessible (spitting through their source files), I'd like to know whether it's ...
32
votes
16
answers
44k
views
How to know if PDF.JS has finished rendering?
I am using PDF.JS to render pdf pages into different canvas elements. my requirement is to capture the output of the canvas and to display it as an image. Is there some event to know if the rendering ...
28
votes
5
answers
90k
views
Pdf.js and viewer.js. Pass a stream or blob to the viewer
I'm having troubles in finding a solution for this:
I retrieve a PDF blob from a SQL filestream field using Javascript in this way (it's a lightswitch project)
var blob = new Blob([screen....
28
votes
3
answers
26k
views
Is there a minimalistic PDF.js sample that supports text selection?
I'm trying PDF.js.
My problem is that the Hello World demo does not support text selection. It will draw everything in a canvas without the text layer. The official PDF.js demo does support text ...
28
votes
4
answers
58k
views
Use PDF.js to statically convert a PDF to HTML
PDF.js is the latest library from Mozilla, and is a standards-based PDF renderer that is written entirely in Javascript. Currently you cannot access the generated HTML, and the library can only be ...
27
votes
3
answers
16k
views
PDF.js not working on IE9
Does anyone have any clue how to get PDF.js to work on IE 9? I have tried everything I can think of to get it to work and no go. I have downloaded the hack.js file and tried adding it before and after ...
26
votes
4
answers
38k
views
pdf.js with text selection
How to make the text in a PDF selectable?
Have tried here. The PDF is written fine, but no text selection
https://github.com/mozilla/pdf.js
https://github.com/mozilla/pdf.js/blob/master/web/...
26
votes
9
answers
30k
views
Prevent PDF auto download by idm using pdf.js
I'm using PDF.Js to embed PDF file for preview, and I removed the script of download and open files from the viewer.js , but when I test the page and PDF file try to show, the Internet Download ...
24
votes
3
answers
70k
views
Render .pdf to single Canvas using pdf.js and ImageData
I am trying to read an entire .pdf Document using PDF.js and then render all the pages on a single canvas.
My idea: render each page onto a canvas and get the ImageData (context.getImageData()), ...
24
votes
1
answer
14k
views
What is a pdf bcmap file?
I am using a pdfjs viewer in my web application and it comes with all these bcmap files. I traced the network traffic and they are not being called for.
I don't really want to add these files to ...