Hello,

The file names are not transliterated at all.

The transliterate module is installed and configured properly.
All other file uploads on the site work as expected.

I'll have a look and see if I can find where's the problem.

Comments

Ivanhoe123’s picture

Status: Active » Needs review

Here's the solution; seems to be working without any problems.
I just added the transliteration function to the place before upload (where the file names are gathered and prepared for saving).

File: multifile.inc, line 801

Change:

    if (!empty($_FILES['files']['orig_name'][$form_key][$key])) {
      $_FILES['files']['name'][$newkey] = $_FILES['files']['orig_name'][$form_key][$key];
    }
    else {
      $_FILES['files']['name'][$newkey] = $_FILES['files']['name'][$form_key];
    }

Into this:

    if (!empty($_FILES['files']['orig_name'][$form_key][$key])) {
      $_FILES['files']['name'][$newkey] = transliteration_clean_filename($_FILES['files']['orig_name'][$form_key][$key]);
    }
    else {
      $_FILES['files']['name'][$newkey] = transliteration_clean_filename($_FILES['files']['name'][$form_key]);
    }

I'll update the status of this issue to "Needs review".

Let me know if you need me to provide anything else.

Thanks

attiks’s picture

Version: 7.x-1.2 » 7.x-1.x-dev

Any change you can make a patch?

Ivanhoe123’s picture

Unfortunately I don't know how to make patches (it's on my todo list for a long time).

attiks’s picture

Status: Needs review » Fixed

Fixed in dev version, wait 12 hours before downloading, or use git to checkout the latest version.

Thanks.

attiks’s picture

Assigned: Unassigned » Jelle_S
Status: Fixed » Patch (to be ported)
Issue tags: +needs backport to 6.x

same problem exists in D6 version

attiks’s picture

Version: 7.x-1.x-dev » 6.x-1.x-dev
Assigned: Jelle_S » Unassigned
Status: Patch (to be ported) » Fixed
Issue tags: -needs backport to 6.x

fixed in D6 as well

Ivanhoe123’s picture

Thanks for fixing this quickly :)

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.