Home >Web Front-end >HTML Tutorial >The solution to the problem that the browser will not display the css setting when the font of the local computer is referenced by the web page_html/css_WEB-ITnose

The solution to the problem that the browser will not display the css setting when the font of the local computer is referenced by the web page_html/css_WEB-ITnose

WBOY
WBOYOriginal
2016-06-24 11:44:191246browse

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8" /><title>无标题文档</title></head><style> @font-face { font-family: Venera; font-weight: bold; src: url(Venera-900.otf); } p{ font-family:Venera; font-size:30px;}</style><body><p>10000</p></body></html>

You only need to place the fonts used in your web page into your folder and cite them just like you would cite images. You can load the font into it and then call the name you set when setting the font type.

Note: This writing method is invalid under ie8 and below under Google and Firefox

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn