CSS3 fonts

@font-face is a module in CSS3. It mainly embeds self-defined Web fonts into your web pages. With the emergence of the @font-face module, we no longer need to use fonts in Web development. No more worries about only using web-safe fonts! Some people will definitely ask, can IE support such a thing? Let me tell you that the @font-face function has been supported as early as IE4. You will definitely be surprised. If you see some English websites or blogs and see some beautiful custom Web fonts, such as the logo on the homepage, Tags and the handwritten English style on the page, in a word these are all implemented by @font-face.


First let’s take a look at the grammatical rules of @font-face:

@font- face {

[font-family: ;]?

[src: [ [format(#)]? | < font-face-name> ]#;]?

[unicode-range: #;]?

[font-variant: ;]?

[font-feature-settings: normal|#;]?

[font-stretch: ;]?

[font-weight: ];

[font-style:

使用CSS3,网站终于可以使用字体以外的预先选择“合法”字体。

注意: 需要引入外部字体文件显示效果。


Continuing Learning
||
php中文网(php.cn)
submit Reset Code
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!