Embedded PDFs fail to load when PDF.js disabled

RESOLVED WORKSFORME

Status

()

Firefox
PDF Viewer
P3
normal
RESOLVED WORKSFORME
6 years ago
3 years ago

People

(Reporter: Matt_G, Unassigned)

Tracking

19 Branch
x86
All
Points:
---

Firefox Tracking Flags

(firefox19-)

Details

(Whiteboard: [pdfjs-c-integration])

(Reporter)

Description

6 years ago
It seems that if you disable pdf.js, you can't have embedded PDFs which means that these forms don't work and you can't submit forms. This is actually breaking some "major" university admin software.
(Reporter)

Updated

6 years ago
tracking-firefox19: --- → ?
If possible, let's get more details. So far I have tried a few scenarios and using simple documents I am not able to get into a bad situation I can't get out of easily. These are the scenarios I tried:

- Install 18.0.1 and Adobe Acrobat (latest) setting it as the default PDF reader in the Applications section in the Options. Open a PDF inline. Close it. Install the latest Fx19b3 on top of it. Open a PDF. It opens inline.

- Same as above. Disable PDFjs in about:config. Opening inline PDFs still works.

- Install Fx19.0b3 and set Firefox PDF Preview as the default pdf reader. Open a PDF document. It opens inline. If you disable from about:config. The document is saved and double clicking on the item in the download manager will give you an error (application not found). If you go to the Applications section in Options and reset it to Acrobat Reader or Firefox Preview makes it work again.

Comment 2

6 years ago
CC'ing Brendan and Yury, to keep this on their radar.

Matt/Cheng - do we have any more leads? Juan's comment 1 suggests embedded PDFs work correctly if you change the default PDF viewer.
Flags: needinfo?(mgrimes)

Comment 3

6 years ago
I think it might be that people aren't changing the default viewer (it's way way way too difficult) and the in-page behavior is different.

https://input.mozilla.org/opinion/3501238 is the input that this came from but it may be related to forms and not just embedding. 

I also found http://www.pdfobject.com/examples/index.php which is a demo of the Adobe-recommended ways of embedding PDFs.  I don't think any of the examples work (and they all default back to a warning with a download button... not sure what would happen if the warning isn't coded in)

Comment 4

6 years ago
Let me restate the last paragraph, I think the more common use of the embed examples is to have the warning be "please download the Adobe reader" rather than "here's how to download the PDF you want".  Which obviously takes users in circles.
Just as an FYI, if these users are on Mac and reverting to Adobe Reader 11 as their PDF viewer, embedded PDF viewing is not supported. You'll get a warning from Adobe Reader stating as much when you try.
Summary: PDF.js: Issues with embedded PDF → Embedded PDFs fail to load when PDF.js disabled

Comment 6

6 years ago
Given comment 3, untracking.
tracking-firefox19: ? → -
Can we get steps to replicate and HTML example?
Priority: -- → P3
Whiteboard: [pdfjs-c-integration]
(Reporter)

Updated

5 years ago
Flags: needinfo?(mgrimes)

Comment 8

3 years ago
Set pdfjs.disabled to true

Go to this page:

https://www.cs.tut.fi/~jkorpela/html/iframe-pdf.html

The PDFs are downloaded instead of embedded, regardless of the whether or not Adobe Acrobat is set to work by default.

This seems like a pretty serious problem. I'm surprised it's been around so long.
(In reply to Mike Kaply [:mkaply] from comment #8)
> Set pdfjs.disabled to true

Settings pdfjs.disabled to true will not change the selected viewer for the PDF content, it merely blocks any internal PDF viewer code loading. Options/Preferences->Application controls what applications will be chosen for viewing (and this shall be done instead of option above).

Closing as WFM, since there was no response for comment 7.
Status: NEW → RESOLVED
Last Resolved: 3 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.