运维网's Archiver
论坛
›
apache
› Apache FtpServer + Commons-net FTPClient 中文名乱码解决
fjptec-xm
发表于 2017-1-9 08:33:39
Apache FtpServer + Commons-net FTPClient 中文名乱码解决
今天在使用Apache FtpServer 和 Commons-net 中的 FTPClient时出现中文文件名乱码。
使用
ftpClient.setControlEncoding("UTF-8");
即可
注意:该代码需要放在connect方法调用之前,如果放在connect()之后只能解决客户端显示没有问题,但无法上传中文名文件。
页:
[1]
查看完整版本:
Apache FtpServer + Commons-net FTPClient 中文名乱码解决