我将字体真棒库下载到我的本地目录,并将它们放在以下目录中:
index.html
css/font-aswesome.min.css
font/fontawesome-webfont.xxx
这是我的index.html。
<html>
<head>
<meta charset="UTF-8">
<title>Font-Awesome</title>
<link rel="stylesheet" href="css/bootstrap.min.css" type="text/css">
<link rel="stylesheet" href="css/font-awesome.min.css" type="text/css">
</head>
<body>
<i class="fa fa-camera-retro fa-lg"></i> fa-lg
</body>
</html>
并打开index.html,这里没有字体真棒的css样式工具。但在我替换使用CDN链接替换本地href之后,一切正常。 任何人都可以帮助我如何使用本地副本进行字体真棒?
答案 0 :(得分:2)
按照以下步骤操作:
1. Download the font-awesome package from their website.
2. Extract the package where you will find the `font-awesome.css` file.
3. Copy this file to your `CSS` directory.
4. Copy all the fonts files from the extracted font-awesome package to your fonts folder.
5. Finally, add the `font-awesome.css` to your HTML page by giving the respective location of the CSS file.