By clayfreeman on
Change record status:
Published (View all published change records)
Project:
Introduced in branch:
1.1.x
Introduced in version:
1.1.0-alpha1
Issue links:
Description:
The default behavior for all media downloads is to display the file contents in the browser where possible, then fall back to a regular file download. Now it is possible to force Content-Disposition: attachment by setting the query parameter dl=1 on the media entity's canonical path.
For example:
https://www.example.org/media/NN will result in the default behavior where an inline content disposition is preferred, but will fall back to a regular download if inline display is not possible.
https://www.example.org/media/NN?dl=1 will force the file to be saved to disk by the browser.
Development notes:
- Any value other than
dl=1is currently ignored, but may see future use. - Backward compatibility is not guaranteed for any values where
dldoes not equal1. - As a result, the only two supported request scenarios are when
dlis not present, ordl=1.
Impacts:
Site builders, administrators, editors
Module developers
Site templates, recipes and distribution developers