12

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?

neo
  • 579
  • 1
  • 3
  • 14
  • 1
    You should really classify your elements and use CSS to organize your formatting. That fiddle is scary. (Very fitting for Halloween) – usernolongerregistered Oct 31 '13 at 19:18
  • @Agony sorry :D mail agents just support inline css so I had to make it look like this, Happy Halloween by the way :D – neo Oct 31 '13 at 19:33

5 Answers5

13

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

Akash Badiyani
  • 146
  • 2
  • 5
8

As of Jan. 2015, gmail's web client ignores negative margin.

Julian
  • 1,007
  • 1
  • 13
  • 23
3

Apparently, as of Jan. 2022, Gmail's web client still ignores negative margin

3

Apparently, as of Jan. 2023, Gmail's web client still ignores negative margin

0

Apparently, as of Jul 26, 2023, Gmail's web client still ignores negative margin

garek007
  • 395
  • 4
  • 15