【问题标题】:Updating fontawesome to 5.14.0 icons are displayed like squares将 fontawesome 更新到 5.14.0 图标显示为正方形
【发布时间】:2020-08-28 13:42:00
【问题描述】:

在一个网站上我使用的是 fontawesome 5.13.1,所以我想将它更新到 5.14.0,所以替换了 css 文件,在我的网站上查看主页后,图标显示为正方形。

我正在加载这样的库:

<link href="https://www.example.com/css/fontawesome/fas-5.14.0-all.min.css" rel="stylesheet" type="text/css" />

<span data-menu="menu4" style="font-size:46px; color: white; background-color: #8EC057;" class="bubble fas fa-bus-alt">
                                                                                        
                                          </span>

你知道发生了什么吗?

提前致谢

【问题讨论】:

    标签: font-awesome-5


    【解决方案1】:

    使用 Font Awesome 提供的 CDN 不会有任何问题

    <link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.14.0/css/all.css">
    
    <span data-menu="menu4" style="font-size:46px; color: white; background-color: #8EC057;" class="bubble fas fa-bus-alt"></span>

    【讨论】:

    • 感谢您的回答。我已经在 FTP 上上传了文件 fas-5.14.0-all.min.css,它只是重命名了 all-min.css,然后它就可以工作了。所以我认为文件在上传过程中已损坏
    猜你喜欢
    • 2017-02-17
    • 1970-01-01
    • 2017-06-28
    • 1970-01-01
    • 2020-07-24
    • 1970-01-01
    • 1970-01-01
    • 2014-05-23
    • 1970-01-01
    相关资源
    最近更新 更多