【问题标题】:@font-type doesn't load on mobile and IE (wordpress despite correct CSS)@font-type 无法在移动设备和 IE 上加载(尽管 CSS 正确,但仍无法加载 wordpress)
【发布时间】:2015-11-18 09:34:32
【问题描述】:

大家好,我已经进行了大量的挖掘工作,这个持续存在的问题让我发疯了。

我无法为移动设备和 IE 加载我的字体类型。 我的网站是http://kays.vurb.us/

我说的是响应模式下的汉堡图标。它使用带有特殊字体“etmodules”的字母“a”。

这就是我的 CSS 的样子:

@font-face {
font-family: 'etmodules';
src: url('etmodules_v2_4.eot');
src: url('etmodules_v2_4.eot?#iefix') format('embedded-opentype'),
     url('etmodules_v2_4.woff2') format('woff2'),
     url('etmodules_v2_4.woff') format('woff'),
     url('etmodules_v2_4.ttf') format('truetype'),
     url('etmodules_v2_4.svg#etmodules_v2_4regular') format('svg');
font-weight: normal;
font-style: normal;

}

我将文件放在我的主 wordpress 目录中。我不知道我做错了什么。由于它不适用于 IE 和移动设备,因此我尝试查看 IE 开发人员工具,但我无法弄清楚为什么字体会' t 在网站上下载或加载。请帮帮我:(

【问题讨论】:

    标签: css wordpress font-face


    【解决方案1】:

    在主题文件夹中创建一个名为 fonts 或您想要的任何名称的新文件夹,然后在该文件夹中上传您的字体文件

    然后使用绝对路径例如

     src: url(http://www.example.com/wp-content/themes/your-theme/fonts/Arvo-Regular.ttf);
    

    【讨论】:

      猜你喜欢
      • 2015-09-29
      • 1970-01-01
      • 1970-01-01
      • 2018-09-05
      • 2017-12-20
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多