php - 我怎样才能在网站上使用本地字体

标签 php html css webfonts

我想用“monotype corsiva”字体显示我的商业标语,它在 Google 字体上不可用,所以任何人都可以帮助我。

最佳答案

将所有这些字体格式粘贴到您的 css 文件夹 otf/ttf/woff 中。

在你的样式表中添加:-

@font-face {
    font-family: 'MTCORSVA';
    src: url('./MTCORSVA.eot');
    src: local('MTCORSVA'), url('./MTCORSVA.woff') format('woff'), url('./MTCORSVA.ttf') format('truetype');
}

现在使用它来应用字体系列 font-family: 'MTCORSVA';

关于php - 我怎样才能在网站上使用本地字体,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/49399399/

相关文章:

php - 函数返回错误响应

html - 如何在居中的父 div 内创建具有均匀边距的响应框

html - 如何删除页面 CSS 底部的水平滚动条

css - p :panelGrid inside p:panelGrid, 如何删除外部 p :panelGrid? 中的边框

php - 在 PHP 中返回空字符串

php - ActiveQuery 到数组 (asArray)

php - 需要更新 codeigniter 上的用户表密码字段

html - Bootstrap 响应式输入表单域

html - 列中的内容未正确对齐

html - 输入[类型 ="search"] 不适用于 IE9 及以下版本