Some of the concepts in CSS

Source: Internet
Author: User

1. Pseudo-class and pseudo-elements

1, single colon (:) for CSS3 pseudo-class, double colon (::) for CSS3 pseudo-elements. 2. For pseudo elements already in CSS2, such as: before, single colon and double colon: before function is the same.

3, so, if your site only need to be compatible with WebKit, Firefox, Opera and other browsers, it is recommended to use a double colon for pseudo-elements, if you have to be compatible with IE browser, or with CSS2 single colon is more secure.

4, , <input>, <iframe>, these tags are not supported similar to img::before such use (to want the tag to support pseudo-elements, need this element is to be able to insert content, Which means that this element is a container. Elements such as Input,img,iframe cannot contain other elements, so the content cannot be inserted by pseudo-elements)

Some of the concepts in CSS

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.