Outlook software strips out the inline CSS in emails

前端 未结 2 2036
情书的邮戳
情书的邮戳 2021-02-12 19:25

I have an email like the following. The problem is, it works fine on Gmail, but on outlook, all CSS inline statements don\'t work.

One example is:



        
2条回答
  •  余生分开走
    2021-02-12 19:50

    Outlook uses a different way of executing stylesheet. Is not SMTP settings or email settings. It depends on how the email service like Gmail, Outlook and Yahoo displays the CSS. How Outlook styles = How IE styles.

    I've used Mailchimp did this for every p element I used and it does not looks exactly the same in Outlook and Gmail but is the closest I can get.

    The guide I used for Outlook is this. Do note that you have to join their community ( free) to get the Outlook guide, which I think is worth it and save you the trouble. https://www.emailonacid.com/resources

    The previous link should explain to you but if you want more information, you can always look the below two links that I used as well.

    For Outlook/Hotmail, they usually have a mso syntax in front of the styling like http://templates.mailchimp.com/development/css/outlook-conditional-css/

    For certain elements that email provider use, you can refer here. https://www.campaignmonitor.com/css/

    Spend some time creating a email template that works for all email services and modify it next time to suit your needs saves much more time and effort than starting from scratch.

提交回复
热议问题