CSS-邮件模板中的负边距问题 [英] css - problems with negative margin in mail template

查看:126
本文介绍了CSS-邮件模板中的负边距问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在创建一个html邮件模板,我使用了一个功能区,因此我需要将其移到边框之外.您可以在此处查看代码: http://jsfiddle.net/GEqk7/

首先要使用position: relative;,我给色带设置了负数,但事实是gmail,yahoo和...对position的支持不佳.因此,我决定使用负边距,但是gmail和yahoo都不支持.

有没有办法做到这一点?

解决方案

大多数电子邮件客户端不支持负保证金.您将不得不将该功能区图像作为背景.

I'm creating a html mail template, I used a ribbon so I need to a move it a little bit past border. you can see the code here: http://jsfiddle.net/GEqk7/

To do this first i used position: relative; and I gave the ribbons a negative position but the thing is that position is not well supported by gmail and yahoo and ... . So I decided to use negative margin but it looks like gmail and yahoo don't support that either.

is there a way or a fallback to to do this?

解决方案

Most of the Email clients dont support negative margin. You will have to take that ribbon image as a background.

这篇关于CSS-邮件模板中的负边距问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆