Closed Bug 1719170 Opened 3 years ago Closed 3 years ago

content-disposition: inline, filename=foo.pdf not working

Categories

(Firefox :: File Handling, defect)

Firefox 89
defect

Tracking

()

RESOLVED INVALID

People

(Reporter: amit.dor.shifer, Unassigned)

Details

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36

Steps to reproduce:

serve a pdf with the following headers:
Content-Disposition: inline; filename="foo.pdf"
Content-Type: application/pdf;charset=UTF-8

Actual results:

foo.pdf is downloaded to host filesystem.

Expected results:

pdf should appear inline in the browser window, without creating a file on the host filesystem. (my understanding of https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Disposition)

Component: Untriaged → PDF Viewer
Status: UNCONFIRMED → NEW
Ever confirmed: true
Component: PDF Viewer → File Handling

The severity field is not set for this bug.
:Gijs, could you have a look please?

For more information, please visit auto_nag documentation.

Flags: needinfo?(gijskruitbosch+bugs)

Apologies this went unattended for so long.

I can't reproduce this myself (ie I get the expected behaviour). Can you provide an online testcase that reproduces this issue for you? And in your local Firefox, are PDfs configured to open in Firefox? (You can check in the settings, search for "PDF".)

Flags: needinfo?(gijskruitbosch+bugs) → needinfo?(amit.dor.shifer)

(In reply to :Gijs (he/him) from comment #2)

Apologies this went unattended for so long.

I can't reproduce this myself (ie I get the expected behaviour). Can you provide an online testcase that reproduces this issue for you? And in your local Firefox, are PDfs configured to open in Firefox? (You can check in the settings, search for "PDF".)

Many thanks. Your input led me in the right direction. Indeed, under Settings / Files and Applications / Applications, PDF content type was set to the 'Save File' action. Don't recall setting it myself. Could that be the default? At any rate, once set as suggested to 'Open in Firefox' - works as expected.

Flags: needinfo?(amit.dor.shifer)
Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.