设置嵌入HTML文档的字体

设置字体(兼容全数浏览器)

@font-face {
font-family: 'iconfont';
src: url("fonts/iconfont/iconfont.eot");
src: url("fonts/iconfont/iconfont.eot?#iefix") format("embedded-opentype"), 
url("fonts/iconfont/iconfont.ttf") format("truetype"), 
url("fonts/iconfont/iconfont.woff") format("woff"),
url("fonts/iconfont/iconfont.svg#icomoon") format("svg");
font-weight: normal;
font-style: normal; }

@font-face { font-family : name ; src : url( url ) ; sRules }

阐明:

name :  字体称呼
url :  应用绝对或相对地址指定OpenType字体
sRules :  格局表定义

设置装备摆设嵌入HTML文档的字体。

@font-face { font-family: dreamy; font-weight: bold; src: url(http://www.example.com/font.eot); }