【问题标题】:why is one glyphicon displayed but not the other?为什么显示一个字形而不显示另一个?
【发布时间】:2017-03-12 07:30:13
【问题描述】:

我在 this page 上使用 Twitter Bootstrap v.3,并且我在页脚中有以下标记:

<footer class="footer text-center">
    <span class="contact-point">
        <span class="glyphicon glyphicon-earphone"></span>
        087-2562153 / 01-2876730
    </span>
    <span class="contact-point">
        <a href="mailto:theupstudio@gmail.com">
            <span class="glyphicon glyphicon-envelope"></span>
            theupstudio@gmail.com
        </a>
    </span>
</footer>

这应该显示一个电话号码和一个电子邮件地址,每个都带有一个字形。但是,由于某种原因,电话图标未正确呈现(显示为正方形),但电子邮件图标很好。

一个字形图标正确显示,而另一个没有?

【问题讨论】:

    标签: html css twitter-bootstrap glyphicons


    【解决方案1】:

    我猜 glyphicon 字体文件已损坏。尝试新的 bootstrap 副本或手动将所有 glyphicon 字体包含到您的 css 中。

    【讨论】:

      【解决方案2】:

      找不到字形字体文件:

      <link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" rel="stylesheet"/>
      <footer class="footer text-center">
          <span class="contact-point">
              <span class="glyphicon glyphicon-earphone"></span>
              087-2562153 / 01-2876730
          </span>
          <span class="contact-point">
              <a href="mailto:theupstudio@gmail.com">
                  <span class="glyphicon glyphicon-envelope"></span>
                  theupstudio@gmail.com
              </a>
          </span>
      </footer>

      我使用 Bootstrap CDN 对其进行了测试,工作正常。

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 2019-09-25
        • 2019-12-13
        • 1970-01-01
        • 1970-01-01
        • 2021-06-06
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        相关资源
        最近更新 更多