Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

This project is archived and is in readonly mode.

Allow option of omitting Content-Disposition from response header when using send_file

#1120

There cases where I am streaming a file through rails, but I don't know whether the content disposition should be inline or attachment, so I'd like to just leave it up to the browser to decide. This patch allows you to do send_file(:disposition => false) and have the Content-Disposition header omitted from the response.

Reported by Paul Barry · September 26th, 2008 @ 05:45 PM

State: invalid
Milestone: 2.x
Assigned to: Pratik Pratik
Importance: none

Activity

  1. Pratik
    Pratik
    • State changed from new to incomplete
    • Assigned user set to Pratik

    Is this allowed by HTTP protocol ? Quoting rfc will surely help :)

    Also, the patch is missing tests.

    Thanks!

    January 5th, 2009 @ 06:27 PM

  2. Paul Barry
    Paul Barry

    It doesn't appear that this is necessary. I originally though the browser was doing different things when the content-disposition header wasn't present vs. when the content-disposition header was set to inline, but after more testing, it appears to behave the same both ways. Sorry for the confusion.

    January 5th, 2009 @ 10:41 PM

  3. Pratik
    Pratik
    • State changed from incomplete to invalid

    Ok great.

    January 5th, 2009 @ 10:44 PM