Closed (won't fix)
Project:
Web File Manager
Version:
6.x-2.18
Component:
Code
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
11 Mar 2012 at 21:46 UTC
Updated:
3 May 2012 at 18:36 UTC
Jump to comment: Most recent file


Comments
Comment #1
nhck commentedThis is related to your browser and what your webserver accepts. Not a part of webfm. Sorry.
Comment #2
phdenis63 commentedPlease don't answer so quickly and try to understand me.

I'm not saying that webfm upload doesn't accepted accentuated characters.
Here is a example of filenames correctly transfered (with webfm upload):
File to upload
File uploaded
I say there is a problem when the filename BEGIN WITH accentuated characters.
Do you have test it on your webserver ?
I can not presume that it is a problem related to my browser and what my webserver accepts because
- accentuated characters are allowed. It is a problem of the position of the accentuated character. I think that a browser accepts or doesn't accept some characters but not depending on the position !
- file upload (with filename beginning with accentuated characters) work perfectly with other file manager such as elfinder on the same webservers and same internet browser (FF or IE)
This in not necessary an error in webfm upload but it can be a drupal function (or php function) not working properly.
If you don't have time to fix this problem, i can try to add a dummy character at the beginning of all my files to upload (e.g underscore) and modify webfm_upload to remove the first character
if (($file = file_save_upload('webfm_upload')) != FALSE) {
// remove first dummy character (to allow accentuated character at the beginning of filename)
.....
// Scale image uploads.
_webfm_image($file);
I can also use elfinder, but I prefer webfm :-)
Regards.
Comment #3
nhck commentedThank you for making the assumption that I did not test this. In fact before answering you I took the time to use 3 different browsers (iron, opera, nightly) to test your problem. I also tested this on two different operating systems (win7x64, redhat enterprise 5). Then I gave you the appropriate answer. I made it short and quick because I assumed you were in a hurry since you did include any information in your bug report on what you tried and what setup you used. So you are welcome.
Furthermore as you can see from your own testing that it is not related to webfm in any case: You have probably investigated it in the api yourself, but as you can see in the file_save_upload function of Drupal the actual moving of the file is done. Depending on what basename returns the file is named. If your upload-file name is not true utf8 and/or your operating system does not support utf8 filenames and/or specific types of filenames the name of the file might be change/truncated and/or broken. As for my testing: Both operating systems handeled the files very different. Have you checked what the file is actually named after it has been uploaded?
Additionally as you know you can right-click and rename the file in webfm - in case it does not fit your needs. I would suggest to use the file meta data one as you can put in an actual title.
Last but not least: If you feel elfinder is doing the job better for you it is totally fine. You are not helping by pointing out that there is different software.
Best regards.
Comment #4
phdenis63 commentedOk. I apologize to have doubted that you have tested my problem before answering.
(and thank you for your quick answer)
I agree with you with the problem of the basename function concerning utf8 characters
(for info, if I take a look with ftp, the file "économique.jpg" after upload with webfm is "conomique.jpg")
Thank you for your suggestion to rename the file in webfm with right-click. It is a solution for now.
If I give elfinder as example, it is only that I think that If it can upload filenames such as "économique.jpg", it must be also possible to do it with webfm.
Thank you for your module.
Best regards
Comment #5
nhck commented