how to download pdf from pdf.js viewer [closed]

I want to download a pdf file from pdf.js viewer but i am not able to download the file.

I also tried to download using this way:

  1. Open the particular pdf in the reader to full screen.
  2. Launch inspect.
  3. Look for a hidden download button with id download styled as display: none,
  4. Change that to display: inline to make it visible.
  5. Click the button to download your pdf.

But still I am not able to download the file.

2 Answers

Are you in a web browser?

In this case you can simply save the page (ctrl + s), and you'll have the pdf.

1

I'm not sure why you are trying to download the PDF via the browser inspector.

When I open a PDF in the browser I get a toolbar with a download button at the top on the right of the screen.

enter image description here

You Might Also Like