Quantcast
Channel: Zammad - Community - Latest posts
Viewing all articles
Browse latest Browse all 6728

Problem with application_wrapper.html.erb

$
0
0

Hi fliebe92,

thanks for the reply!
Actually, I don’t know what happened. Both .erb files were completely structured before I copy/pasted them in here.(And the files, at least, still are.) I guess I must’ve done something weird while pasting. Sorry!

I just did a text comparison between the file you linked and the one we use in production, and both are identical.

Just to make sure I applied the linked config and tested again, but we still face the same issue.

When we check the source of the email via outlook, this is what it looks like:

<meta http-equiv="Content-Type" content="text/html; charset=utf-8"><body>

  
    
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <style type="text/css">
      body {
        font-family:Arial,Sans-Serif;font-size:11pt
      }
      img {
        outline: none;
        text-decoration: none;
        -ms-interpolation-mode: bicubic;
      }
      a img {
        border: none;
      }
      table td {
        border-collapse: collapse;
      }
      table {
        border-collapse: collapse;
        mso-table-lspace: 0pt;
        mso-table-rspace: 0pt;
        border: none;
        table-layout: auto;
        display: block;
        width: 100%;
        overflow: auto;
        word-break: keep-all;
      }
      table,
      pre,
      blockquote {
        margin: 0 0 16px;
      }
      td, th {
        padding: 7px 12px;
      }
      th {
        font-weight: bold;
        text-align: center;
      }
      col {
        width: auto;
      }
      p {
        margin: 0;
      }
      code {
        border: none;
        background: hsl(0,0%,97%);
        white-space: pre-wrap;
      }
      blockquote {
        padding: 8px 12px;
        border-left: 5px solid #eee;
      }
      pre {
        padding: 12px 15px;
        font-size: 13px;
        line-height: 1.45;
        background: hsl(0,0%,97%);
        white-space: pre-wrap;
        border-radius: 3px;
        border: none;
        overflow: auto;
      }
    </style>
  
  Test with .erb from github.<br><br><div data-signature="true" data-signature-id="2">
<div>
<div><br></div>
<div>Mit freundlichen Grüßen / kind regards<br>
</div>
</div>
</body>

Again we have an opening tag right after the first tag at the beginning of the file.
However, that is only the case when we have ###html### between the tags inside the .erb file.

As soon as we replace the ###html### variable, the emails html source we send from Zammad and receive in outlook looks like this:

<!DOCTYPE html><html dir="auto"><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <style type="text/css">
      body {
        font-family:Arial,Sans-Serif;font-size:11pt
      }
      img {
        outline: none;
        text-decoration: none;
        -ms-interpolation-mode: bicubic;
      }
      a img {
        border: none;
      }
      table td {
        border-collapse: collapse;
      }
      table {
        border-collapse: collapse;
        mso-table-lspace: 0pt;
        mso-table-rspace: 0pt;
        border: none;
        table-layout: auto;
        display: block;
        width: 100%;
        overflow: auto;
        word-break: keep-all;
      }
      table,
      pre,
      blockquote {
        margin: 0 0 16px;
      }
      td, th {
        padding: 7px 12px;
      }
      th {
        font-weight: bold;
        text-align: center;
      }
      col {
        width: auto;
      }
      p {
        margin: 0;
      }
      code {
        border: none;
        background: hsl(0,0%,97%);
        white-space: pre-wrap;
      }
      blockquote {
        padding: 8px 12px;
        border-left: 5px solid #eee;
      }
      pre {
        padding: 12px 15px;
        font-size: 13px;
        line-height: 1.45;
        background: hsl(0,0%,97%);
        white-space: pre-wrap;
        border-radius: 3px;
        border: none;
        overflow: auto;
      }
    </style>
  </head>
  <body style="font-family:Arial,Sans-Serif;font-size:11pt;">We replaced the html-variable.</body>
</html>

Which is completely fine, and is “as it should be”.


Viewing all articles
Browse latest Browse all 6728

Trending Articles