How to cite custom fonts in html-case articles

css in html refers to custom fonts to achieve custom font style effects (including cases)

  • How are the codes defined for different fonts in web pages? How to quote foreign font files?

Insert picture description here

html case · The code is as follows:

<!DOCTYPE html>
<html>
<head>
	<meta charset="UTF-8">
	<title>江西卓楷</title>
	<link rel="stylesheet" type="text/css" href="statics/css/font.css"/>
	<style type="text/css">
		p{
			font-family: 'JXZK';
			font-size: 20px;
		}
	</style>
</head>
<body>
	<p>我是江西卓凯</p>
</body>
</html>


font.cssAll code of the file:

/*jxzk字体*/
@font-face {
	font-family:'JXZK'; 
	src: url('fonts/JXZK.ttf'); /* 江西拙楷 字体*/
}

Page effect · Screenshot shows:

Insert picture description here


The above is all about "how to css custom fonts in HTML-case articles".

Published 508 original articles · praised 203 · 1.48 million views

Guess you like

Origin blog.csdn.net/qq_35393869/article/details/105555779