我正在设计一个网站,但遇到了问题。我使用bootstrap 3.0.0的Glyphicon设计图片图标“ Cart”。但是,它不起作用。我的错误就像这张照片。请帮我! 谢谢你的收看 下面的代码:
<!--import CSS-->
<link href="../bootstrap/bootstrap.css" rel="stylesheet"/>
<link href="../bootstrap/bootstrap.min.css" rel="stylesheet"/>
<link href="../effect/hover.css" rel="stylesheet"/>
<link href="../css/effecttext.css" rel ="stylesheet"/>
<link href="../effect/hover-min.css" rel="stylesheet"/>
<link href="../css/style.css" rel="stylesheet"/>
----------------------------------------------------
<ul class="nav navbar-nav navbar-right">
<li>
<a href="#">Cart <span class="glyphicon glyphicon-shopping-cart"></span> </a>
</li>
</ul>
-------------------------------------------
<!--Javascript-->
<script src="main.js"></script>
<script type="text/javascript" src="../js/jquery-3.1.1.min.js"></script>
<script type="text/javascript" src="../js/jquery-3.3.1.js"></script>
<script type="text/javascript" src="../js/script.js"></script>
<script type="text/javascript" src="../js/bootstrap.min.js"></script>
答案 0 :(得分:1)
尝试添加CDN
还删除以下几行
<link href="../bootstrap/bootstrap.min.css" rel="stylesheet"/>
和
<script type="text/javascript" src="../js/jquery-3.1.1.min.js"></script>
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" rel="stylesheet" />
<ul class="nav navbar-nav navbar-right">
<li>
<a href="#">Cart <span class="glyphicon glyphicon-shopping-cart"></span> </a>
</li>
</ul>