Excuse me, are you familiar with netbeans? I use netbeans to open a file. it occasionally uses UTF-8 as a gb file. what is the problem?

Source: Internet
Author: User
Excuse me, are you familiar with netbeans? I use netbeans to open a file. it occasionally uses UTF-8 as a gb file. what is the problem? Netbeans UTF-8

This problem occurs:
It can be determined that a CSS file is saved in UTF-8 format.
On the one hand, this file was originally created through netbeans, but now it is saved outside of the project as a separate file to open.

On the other hand, it has been verified using other editors.

When you open this file with netbeans, the preview is displayed correctly:

Yes. When enabled, the following error message is displayed:

If yes is still selected to open the file, the file is garbled:


Why?


Reply to discussion (solution)

Apparently, you have not set the default character set for netbeans.

Apparently, you have not set the default character set for netbeans.

Where can I set the default character set? I found it for a moment. I always thought that character sets can be set only when a project is created.

In addition, even if the default character set is set in wood, the problem is that Netbeans regards a UTF-8 file as a GB2312 file.
In other words, Netbeans cannot automatically recognize the file encoding format. it only opens the file in the set mode (assuming that the current default character set is set to GB2312 ).

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.