【发布时间】:2015-09-22 20:15:31
【问题描述】:
我在我的项目中使用 Bootstrap.css 和 font-awesome.css 以及 cdn 链接。 例如: 对于引导程序
<link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootswatch/3.3.0/cerulean/bootstrap.min.css">
字体真棒
<link href="//maxcdn.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css" rel="stylesheet">
在我的代码中,我使用 class="glyphicon glyphicon-search" 等。它工作正常。 但是当我从相同的链接下载css文件时。并在本地添加依赖项,它没有运行。错误说
GET http://localhost:8451/ProntoDemo/resources/fonts/glyphicons-halflings-regular.woff
GET http://localhost:8451/ProntoDemo/resources/fonts/glyphicons-halflings-regular.ttf 404 (Not Found)
我不明白问题出在哪里。请帮我在本地运行。 喜欢
<link rel="stylesheet" href="./resources/css/bootstrap.min.css">
【问题讨论】:
-
你能具体说明你是如何修改你的吗
css -
您收到 404 错误 - 找不到文件。检查您的日志以查看您的 url 解析到的文件路径。
-
我在我的项目目录中创建 bootstrp.min.css 文件并将其添加到我的 html 页面中。
标签: html css twitter-bootstrap webfonts