Can I use ANSI charset in HTML files?

3

In order to be able to publish texts daily using any editor like notepad ++, for example, I would type the words with an accent and save them in the HTML file. I have been reading that UTF-8 it is necessary to put a code for the accents. For example is is é .

I would like to know if I can use ANSI charset in HTML files so you do not need to be typing UTF-8 tags for each special character or accent.

    
asked by anonymous 16.06.2014 / 17:11

1 answer

2

You're confused, UTF-8 has nothing to do with "HTML entities" as é . UTF-8 is a way to represent the characters in bytes , as well as ANSI (Windows-1252, similar to ISO-8859-1, or Latin 1). The difference is that ANSI characters always use 1 each, while UTF-8 uses 1 to 4 bytes . Therefore, with UTF-8 it is possible to represent a much larger number of special characters.

Nowadays, it is highly recommended to use UTF-8 instead of ANSI or other more limited encoding. If the files are saved as UTF-8 and HTML is being delivered by the server with the correct HTTP headers, everything will work fine.

    
16.06.2014 / 19:11