The basename() function of PHP is locale-aware and has a bug
with filenames starting with multibyte character if the locale
of PHP is not explicitly set (by php.ini, httpd.conf, exporting
the LANG environment variable or setlocale() function).
See: PHP Bug #37738 basename does not work with Japanese
http://bugs.php.net/37738
DokuWiki is also affected by this bug.
For example, try to download a code snippet on the url below.
The download filename should be "文書_1.txt", but you can find
the filename is "_1.txt" because of the bug mentioned above.
http://www.dokuwiki.org/plugin:preservefilenames
Unfortunately, most of the PHP servers are running without
setting their locales. So workarounds are needed to avoid the
basename bug, that is, to make DokuWiki works correctly.
Since changing locale has big effect, I think the best solution
to cope with this bug is to provide a locale-unaware,
basename-equivalent function by DokuWiki.
If that function is provided, I think many people who are
mainly using multibyte characters will be happy.