Home  >  Article  >  Web Front-end  >  How to solve the problem of Chinese garbled characters in Sublime Text

How to solve the problem of Chinese garbled characters in Sublime Text

一个新手
一个新手Original
2017-09-18 09:15:402804browse

Sublime Text is a simple and powerful text editor. However, it uses UTF8 encoding by default, which causes the Chinese in many GBK-encoded files to be displayed as garbled characters.

Fortunately, there is a plug-in that specifically solves this problem: ConvertToUTF8.
To install this plug-in, you must first install Package Control of Sublime Text. The installation method is as follows:

1. Open Sublime Text, press Ctrl + ~ to open the console, at https://packagecontrol.io/ installation
Select the corresponding installation code according to your Sublime Text version, enter the code into the console and press Enter. Package Control will be automatically downloaded and installed. After the installation is completed, you need to restart Sublime Text.

2. Next, you can install ConvertToUTF8!

Press Ctrl + Shift + P to open the universal search box, then enter install package and press Enter.
At this time, all packages list will be loaded.

After seeing the list, enter ConvertToUTF8 and press Enter, the package will be downloaded and installed.
After installation, there is no need to restart Sublime Text. You will be pleasantly surprised to find that the original Chinese garbled characters can be displayed normally.

Sublime Text is a simple and powerful text editor. However, it uses UTF8 encoding by default, which causes the Chinese in many GBK-encoded files to be displayed as garbled characters.

Fortunately, there is a plug-in that specifically solves this problem: ConvertToUTF8.
To install this plug-in, you must first install Package Control of Sublime Text. The installation method is as follows:

1. Open Sublime Text, press Ctrl + ~ to open the console, at https://packagecontrol.io/ installation
Select the corresponding installation code according to your Sublime Text version, enter the code into the console and press Enter. Package Control will be automatically downloaded and installed. After the installation is completed, you need to restart Sublime Text.

2. Next, you can install ConvertToUTF8!

Press Ctrl + Shift + P to open the universal search box, then enter install package and press Enter.
At this time, all packages list will be loaded.

After seeing the list, enter ConvertToUTF8 and press Enter, the package will be downloaded and installed.
After installation, there is no need to restart Sublime Text. You will be pleasantly surprised to find that the original Chinese garbled characters can be displayed normally.

The above is the detailed content of How to solve the problem of Chinese garbled characters in Sublime Text. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn