Bug: Viewfile Script Uses Topic Name Instead of File Name
There's a bug with the TWiki/bin/viewfile script in the current distribution. This module will always change the name of the download filename to the name of the topic unless you retrieve the latest version. The reason this occurs is as follows: If the requested version is the latest version, viewfile redirects the
CGI to download the latest copy on the server. Otherwise it manually builds a download stream of the file from rcs. When it builds the download stream from rcs, it doesn't include a Content-Disposition: tag, which is how you specify what the download filename is. I fixed viewfile on my site to do this. If you want this fix (also fixes the same problem from the Attachment screen), use
viewfile.zip
Environment
| TWiki version: |
|
| TWiki plugins: |
|
| Server OS: |
|
| Web server: |
|
| Perl version: |
|
| Client OS: |
|
| Web Browser: |
|
--
EdLott - 08 Dec 2001
Cloned this topic from
Plugins.VersionLinkPluginDev since it should be fixed in the TWiki core code.
--
PeterThoeny - 10 Dec 2001
Fix record
Thanks for the patch! This is now in the
TWikiAlphaRelease in slightly simplified form. Tested on a local TWiki and works OK.
--
RichardDonkin - 22 Mar 2002
Category:
TWikiPatches