http://blog.chinaunix.net/uid-21843387-id-106001.html
详细介绍了文件所在电脑的配置、文件格式、输出端格式的关系
windows下用putty软件的解决办法:
1、putty的Window->Translation->Remote character set设置为UTF-8 保证putty能够输入中文
2、修改.vimrc如下
set encoding=euc-cn “支持识别中文编码文件
set fileencodings=
set termencoding=utf-8 ”保证输出到客户端的格式是UTF-8
如上,就可以正确显示和输入中文了