Specify the encoding of a CSS file in XML - Specify the encoding of a CSS file in XML - Specify the encoding of a CSS file in XML - encoding of a CSS file in XML

encoding of a CSS file in XML

The procedure required to specify the encoding of a CSS file in XML metalanguage is not complex, but requires some rules to follow, depending in particular on the purpose for which an XML document and the data that it manages to execute.

In general, it is possible to say that the encoding of a CSS file is determined:

  • From the value associated with the @charset element defined in the file itself;
  • From the possible reference declaration system, in XHTML this may be, for example, the charset attribute for a given element;
  • From the possible use of the HTTP charset argument in the Content-type of the file.

A simple encoding specification can be for example the following:

@charset "iso-8859-1"

In the proposed case, Latin-1 iso-8859-1 encoding has been specified.

How useful was this post?

Click on a star to rate it!

Average rating / 5. Vote count:

As you found this post useful...

Follow us on social media!

We are sorry that this post was not useful for you!

Let us improve this post!