truncate filename given in content-disposition (#3245)
This commit is contained in:
parent
ed2537168a
commit
c9c0e90c33
2
Avis.py
2
Avis.py
|
@ -47,7 +47,7 @@ class AvisOdt:
|
|||
# Tell the browser that the resulting page contains PDF
|
||||
response.setHeader('Content-type', 'application/%s' % fileType)
|
||||
response.setHeader('Content-disposition',
|
||||
'inline;filename="%s.%s"' % (self.id, fileType))
|
||||
'inline;filename="%s.%s"' % (self.id[:200], fileType))
|
||||
# Returns the doc and removes the temp file
|
||||
f = open(tempFileName, 'rb')
|
||||
doc = f.read()
|
||||
|
|
Reference in New Issue