开发者

Why doesn't Microsoft Outlook respect list styles when sending HTML emails?

I have the following code and for the life of me I can't get it to work in Microsoft Outlook.

<ul style="margin-lef开发者_如何学JAVAt: 50px; line-height: 50px; list-style: none;">
    <li style="font-size: 1.5em; list-style: none;">[UniqueCode]</li>
</ul>

Is there another way to achieve the same result? I am attempting to send a HTML email to a group of people.


Have a look at Campaign Monitor's guide to CSS support in HTML emails.

list-style-image, list-style-position and list-style-type are not supported in Outlook 2007 or Outlook 2010.

Using table cells for layout is standard practice in HTML email builds because CSS support in Outlook is really bad.

Try using table cells with exact widths specified for the layout of your list, and have each item in a new row or separated by <br>s.


I tried giving the <ul> a text color that matched the background and then used a <span> assigning the correct color for the text. For instance, if you were using a #c4c4c4 background with black text.

<ul style="list-style: none;color:#c4c4c4;">
  <li><span style="color:#000000;">Something</span></li>
</ul>

The bullets, if displayed, blend in with the background, but the text will show.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜