Home  >  Article  >  Web Front-end  >  Usage of CSS @charset rule

Usage of CSS @charset rule

WBOY
WBOYforward
2023-09-02 10:57:021239browse

CSS @charset 规则的用法

If you write your document using a character set other than ASCII or ISO-8859-1, you may need to set a @charset rule at the top of your style sheet to indicate the character set used Style sheet writing.

@charset Rules must be written at the beginning of the style sheet, without spaces in front. The value is enclosed in quotes and should be one of the standard character sets.

Example

Let’s see an example

<style>
   <!--
      @charset "iso-8859-1"
      .......other CSS rules .....
   -->
</style>

The above is the detailed content of Usage of CSS @charset rule. For more information, please follow other related articles on the PHP Chinese website!

Statement:
This article is reproduced at:tutorialspoint.com. If there is any infringement, please contact admin@php.cn delete