Displaying 1 result from an estimated 1 matches for "philestructure".
Did you mean:
filestructure
2007 Dec 13
0
How do I force download with LiteSpeed?
Hi!
Searched a long time for this, but haven''t found an answer.
I''m trying to make the user download a special file, no matter what
mediatype it is (could be jpg, pdf or doc for example).
My code right now is this:
def download_path( _id = params[:id])
result = Philestructure.find( _id )
headers[''X-LiteSpeed-Location''] = "/downloads/
#{result.phile.file_name}"
headers[''Content-Description''] = "File Transfer"
headers[''Content-Type''] = ''application/force-download''
headers['...