标签: html-email

mso-line-height 和 mso-text-raise 在 Outlook 2013 中不起作用?

我有一个包含 3 列的页脚,这些列都严格嵌套在 HTML 电子邮件模板的基于表格的布局中。我正在尝试修复页脚,其中第三列的行高与前两列的顶部基线不匹配。

我一直在进行研究,看看是否有解决方案,并尝试了声明的mso-line-height-rule:exactly; mso-text-raise:44px;最后一列的变体line-height,但它似乎没有任何效果。

您可以在下图中看到,最后一列的文本向下移动,并且文本的间距与在电子邮件中正确呈现的第二张图像有所不同。

Outlook 2013(在 Amazon Workspace - Windows 7 Pro 中):

2013年展望

Mac 版 Outlook 2011:

在此输入图像描述

页脚代码:

            <!-- Footer -->
            <table width="100%" border="0" cellspacing="0" cellpadding="0" bgcolor="#ffffff">             
                <tr>
                    <td class="content-spacing" style="font-size:0pt; line-height:0pt; text-align:left" width="1"></td>
                    <td align="center">
                        <table width="650" border="0" cellspacing="0" cellpadding="0" class="mobile-shell">
                            <tr>
                                <td class="td" style="width:650px; min-width:650px; font-size:0pt; line-height:0pt; padding:0; margin:0; font-weight:normal; Margin:0">
                                    <table width="100%" border="0" cellspacing="0" cellpadding="0">
                                        <tr>
                                            <td>
                                                <table width="100%" border="0" cellspacing="0" cellpadding="0" class="spacer" style="font-size:0pt; line-height:0pt; text-align:center; width:100%; min-width:100%"><tr><td height="25" …
Run Code Online (Sandbox Code Playgroud)

css outlook html-email outlook-2013 outlook-2011

0
推荐指数
1
解决办法
8971
查看次数

CSS nth-child 选择器在 Outlook/Gmail 中不起作用

我在执行某些操作时发送邮件,其中一些包含 HTML 表。我想对表中 2 行中的 1 行进行着色,为此我使用以下规则:

tr:nth-child(even) {
  background-color: #c4409720;
}
Run Code Online (Sandbox Code Playgroud)

在 mailhog 中,输出是完美的并且可以工作,但是一旦在 Outlook 或 Gmail 中查看电子邮件,行就不会着色。请注意,我不知道我会提前有多少行,因为邮件模板是用列表和循环填充的。

我猜这些邮件客户端不支持选择器?

那么我怎样才能以那些邮件客户端能够理解的方式实现这一点呢?

提前致谢 !

outlook gmail mako css-selectors html-email

0
推荐指数
1
解决办法
5850
查看次数

发送带有midi文件的HTML电子邮件,该文件需要在打开时自动播放

我正在尝试完成以下操作,我正在使用PHP Mailer发送HTML电子邮件,该文件读取html文件并在HTML文件中嵌入midi文件,然后发送电子邮件,然后midi文件应自动开始播放一旦打开电子邮件,这是可能的,因为它似乎不起作用,我正在使用Evolution来查看电子邮件.

我的代码看起来像这样,

HTML文件"如果我在浏览器中打开它,它会播放但不会在电子邮件中播放"

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">

<head>
    <title>Template</title>
</head>
<body>

    <h1>Song is playing</h1>
    <embed src="http://test.mydomain.co.za/song.mid" autostart="true" loop="true" hidden="true" />
</body>
</html>
Run Code Online (Sandbox Code Playgroud)

PHP邮件代码

    $email = $_GET['email'];

    //Including the PHP mailer class
    require_once 'class.phpmailer.php';

    $mail = new PHPMailer(true); //defaults to using php "mail()"; the true param means it will throw exceptions on errors, which we need to catch

    try {
      $mail->AddAddress($email);
      $mail->SetFrom('webmaster@mydomain.co.za', 'Webmaster');
      $mail->AddReplyTo('webmaster@mydomain.co.za', 'Webmaster');
      $mail->Subject = 'PHPMailer Test Subject via mail(), advanced';

      $mail->AltBody …
Run Code Online (Sandbox Code Playgroud)

html php midi html-email phpmailer

-1
推荐指数
1
解决办法
793
查看次数

如何将我的电子邮件置于Hotmail中心?

我正在使用http://www.emailonacid.com测试我的HTML电子邮件,Hotmail导致问题.

此表显示为左对齐,我无法弄清楚原因:

 <div align="center">
     <table align="center" width="200" style="background:red">
       <tr>
         <td>Please Help</td>
       </tr>
     </table>
 </div>
Run Code Online (Sandbox Code Playgroud)

它在IE中看起来不错,但在FF中却看不到.

email hotmail html-email

-5
推荐指数
1
解决办法
3332
查看次数

从PHP发送HTML电子邮件

MYSqL工作正常,但我没有收到电子邮件的原因?

<?php
    //include the connection file

    require_once('connection.php');

    //save the data on the DB and send the email

        if(isset($_POST['action']) && $_POST['action'] == 'submitform')
        {
        //recieve the variables

        $name = $_POST['name'];
        $email = $_POST['email'];
        $url = $_POST['url'];
        $comment = $_POST['comment'];
        $ip = gethostbyname($_SERVER['REMOTE_ADDR']);

        //save the data on the DB

        mysql_select_db($database_connection, $connection);

        $insert_query = sprintf("INSERT INTO contacts (name, email, url, comment, date, ip) VALUES (%s, %s, %s, %s, NOW(), %s)",
                            sanitize($name, "text"),
                            sanitize($email, "text"),
                            sanitize($url, "text"),
                            sanitize($comment, "text"),
                            sanitize($ip, "text"));

        $result = mysql_query($insert_query, …
Run Code Online (Sandbox Code Playgroud)

php forms email sendmail html-email

-5
推荐指数
1
解决办法
167
查看次数