Css annotation bug in ie6

Source: Internet
Author: User

When I wrote a page today, after adding a Chinese note to the style sheet, I found that it was invalid under ie6. I found the cause on the Internet and shared it as follows:

Because css encoding and html encoding are inconsistent, the style sheet cannot be annotated.

If the following conditions are met, the following style cannot be commented out:
1. css has Chinese comments
2. css is ANSI encoded
3. html is UTF-8 encoded

Solution:

1. Remove Chinese comments and use English comments.
2. Unified css and html Encoding

The second solution is recommended.

Ps: css for uft-8, html For ANSI will not be invalid.

Link: http://hi.baidu.com/351net/blog/item/d014ce0e517eace036d122a2.html

Related Article

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.