Hi, I uploaded many files to my FTP and didn't notice that Total Commander incorrectly detected the encoding.
Now it uploaded the files without UTF8 encoding (I had set it to auto-detect), which makes the file names show up correctly within total commander (at least where it was possible to create the files), but neither on the server nor on other clients (with utf8 support) do they show up correctly.
So is there an easy way to convert these files and folders recursively from "ANSI (local code page)" (I assume that was what the auto mode selected) into utf8? Like a search and replace?
Also, how can I prevent this from reoccurring? How does the auto-detection detect utf8 support? I use proftpd as server.
FTP fix incorrect file name encoding
Moderators: Hacker, petermad, Stefan2, white
Re: FTP fix incorrect file name encoding
Delete them and upload them again?agowa338 wrote: 2022-12-24, 06:21 UTC So is there an easy way to convert these files and folders recursively from "ANSI (local code page)" (I assume that was what the auto mode selected) into utf8? Like a search and replace?
Disable automatic encoding and choose a fixed encoding for your server.
Explained in Help:agowa338 wrote: 2022-12-24, 06:21 UTC How does the auto-detection detect utf8 support? I use proftpd as server.
Help wrote: Encoding of file name
Determines how the file names are sent by the server. Normally servers send the name with the local encoding of the server, usually a Windows/ANSI codepage. Some newer servers also support UTF-8 encoding, which allows you to use Unicode file names. When you set this option to automatic, TC will send the command
OPTS UTF8 ON
to determine whether the server supports Unicode. TC will revert to ANSI encoding (same codepage as the client) if the server doesn't confirm the above command. TC also checks the SYST command response for the reported encoding, e.g. UNIX Type: L8 , CP:1252.
You can also choose the codepage manually from the list, or enter a numeric codepage value if the accents do not appear correctly.
Re: FTP fix incorrect file name encoding
2agowa338
I am not quite sure if you also have problems whith the content of the files being wrong after upload - but if you have - read below:
After you have connected to the FTP server you can select the transfer mode: https://madsenworld.dk/tcmd/ftptransfermode.png
If you open the dropdown box and click on "Automatic" - you can remove the filetype of your current upload.
Or you can select "Binary (archives, doc ets.)"
I am not quite sure if you also have problems whith the content of the files being wrong after upload - but if you have - read below:
After you have connected to the FTP server you can select the transfer mode: https://madsenworld.dk/tcmd/ftptransfermode.png
If you open the dropdown box and click on "Automatic" - you can remove the filetype of your current upload.
Or you can select "Binary (archives, doc ets.)"
Help -> FTP wrote:- Define the transfer mode for transferred files?
You can define the transfer mode in the FTP toolbar, which appears after a connection is made. The mode can be set to binary, text, and automatic. The shortcut is CTRL+SHIFT+M. In automatic mode, the actual transfer mode is determined by the file association. Please note: You cannot set the transfer mode when connecting via a HTTP proxy - the proxy itself defines the mode via MIME types
License #524 (1994)
Danish Total Commander Translator
TC 11.51 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1391a
TC 3.60b4 on Android 6, 13, 14
TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
Danish Total Commander Translator
TC 11.51 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1391a
TC 3.60b4 on Android 6, 13, 14
TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
Re: FTP fix incorrect file name encoding
Thankfully I've uploaded everything in Binary mode already. But my current problem is I've scrubbed the files from countless locations and uploaded them. Now I either need a way to list all with incorrect encoding to manually fix them OR, preferably, get the incorrectly auto-encoded filenames converted to utf8 automatically...