Myeclipse解决乱码

xiaoxiao2021-02-28  93

1 .general->content types,设置Text对应的default encoding值为UTF-8或为空,然后点击update即可。也可能点击Text进入java source file属性,设置default encoding值为UTF-8或为空,点击update。 1.2 general->editors->text editors->spelling。设置encoding属性为UTfF-8. 1.3 general->workspace。设置text file encoding为UTF-8. 1.4 myeclipse ->files and editors。此处通常无需修改,保持默认即可。默认ASP and PHP和JSP的encoding为ISO Latin-1,其他属性 的encoding值为ISO 10646/Unicod(UTF-8) 2 右击工程的properties属性,选择resource,设置text file encoding值为UTF-8. 以上方法基本可以解决所有乱码问题,如果再不行,你可以选择某个java文件,右击properties属性,进入resource选择text file encoding的编码方式为UTF-8.或者将单个文件放入 txt文本 ,确保不乱码后再复制进来。这两方法只适合少量文件乱码,不适合整个工程乱码。
转载请注明原文地址: https://www.6miu.com/read-28139.html

最新回复(0)