The problem
This is about the behavior of
TWiki::UI::Upload::upload()
. If the name of an attached file contains problematic characters, they are replaced or removed and the file is saved with a different file name. When that happens, the original and changed names are supposed to be shown on the
oopsattention
page. But after
TWiki::UI::execute()
was modified to call
TWiki::UI::Oops::oops()
rather than redirecting to the
oops
script, the name change listed stopped working.
The fix
- The "uploaded_name_changed" message in
templates/messages.tmpl
- It assumed the
oops
script to be executed and was referring to %URLPARAM{param1}%
, %URLPARAM{param2}%
, ..., which need to be replaced with %PARAM1%
, %PARAM2%
, ...
- TWiki::UI::Oops::oops()
-
%IF{"'%PARAM1%'=''" then="..." else="...}%
didn't work. To make it work...
-
$session->handleCommonTags(...)
before %PARAM1%
, %PARAM2%
, ... replacement needs to be removed
- Remaining
%PARAM\d+%
needs to be replaced with a null string
--
TWiki:Main/HideyoImazu
- 2014-04-17