gpt4 book ai didi

html - @font-face 只对内联字体系列不起作用

转载 作者:行者123 更新时间:2023-11-28 10:03:26 25 4
gpt4 key购买 nike

我需要你的帮助,我正在尝试更改 PHPMAILER 中电子邮件的字体,只是识别内联 css,头部的样式标签不起作用(我不知道为什么)。

你知道我该怎么做才能将 @font-face 内联到 tbody 中吗?

$contenido = '<!doctype html>
<html>
<head>
<style>
@font-face {
font-family: dinot-regularregular;
src: url(xxxxxxxxxxxx/css/Font/dinot-regular-webfont.woff);
}
body {
font-family: dinot-regularregular;
}
</style>
</head>

<body>';
$contenido .= '
<table>
<tbody style="font-family:dinot-regularregular; font-size:16px; color:#666666;">
// Content
</tbody>
</table>';

感谢您的帮助。

最佳答案

在电子邮件客户端的支持下,格式化电子邮件非常挑剔。如果您阅读这篇文章,他们会提供一个表格,显示有多少电子邮件客户端支持 font-face。这不是一个很高的数字。

https://www.campaignmonitor.com/blog/post/3044/does-font-face-work-in-email

关于html - @font-face 只对内联字体系列不起作用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/24636181/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com