Forum

[T#1086] Bad Conten...
 
Notifications
Clear all

[T#1086] Bad Content-Type when download file in 3.3.0

3 Posts
2 Users
0 Reactions
3,917 Views
Vincent
(@vdeverre)
Posts: 38
Active Member
Topic starter
 
[#1140]

Hi.
I have install 3.3.0 from 3.2.

When I download file, my browser do not show the default application to open it.

The problem is the Content-Type is bad.
The content-type is: Content-Type application/force-download; name="file_1"
and must be: Content-Type application/force-download; name="myfile_original.xls"

Content-type contains database field documentversion.fullName and must be documentversion.fileName

Can you fix it ?


 
Posted : 30 Apr 2013 13H35
Vincent
(@vdeverre)
Posts: 38
Active Member
Topic starter
 

I found the problem :woohoo:
To fix it, edit the file tool/download.php

line 26
orginal: $name = ($obj->fullName)?$obj->fullName:$obj->fileName;
fix: $name = ($obj->fileName)?$obj->fileName:$obj->fullName;

line 33
orginal: $name = ($obj->fullName)?$obj->fullName:$obj->fileName;
fix: $name = ($obj->fileName)?$obj->fileName:$obj->fullName;


 
Posted : 30 Apr 2013 13H51
(@babynus)
Posts: 14952
Member Admin
 

You're right.
Change in V3.3 is not acurate.

Document version name should be :
- documentversion.fileName for old versions (before V3.3)
- documentversion.fullName for new versions (after V3.3)

it should also be configurable to download either with uploaded filename (default before V3.3) or formated version reference (default after V3.3)

Ticket #1086 recorded


 
Posted : 30 Apr 2013 14H01
Share:

Scroll to Top