N
N
nivaech2020-10-27 12:56:05
HTML
nivaech, 2020-10-27 12:56:05

Is there an equivalent object-fit: cover for desktop Outlook?

The html file has a header with an image.
Its width should be no more than 736px and its height 459px.

The problem would be easily solved by using background-size: cover or object-fit: cover, but these are not supported by
Outlook desktop and therefore the picture is either full size or just flattened.

The block with the image now looks like this:

<tr>
                            <td style="border-collapse:collapse; line-height:0; mso-table-lspace:0; mso-table-rspace:0; padding:0">
                                <img src="https://d2zjge1f9hor5r.cloudfront.net/media/hero_image/412/347/latkevodka_11.jpg" width="736" height="459" alt="" style="display:block; width:100%; max-width: 736px" />
                            </td>
                        </tr>


But it doesn't work.
How to write object-fit: cover / background-size: cover analog for Outlook so that the image has full height and width, and at the same time it is correctly displayed within the container?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
I
Ilya Olovyannikov, 2020-10-27
@cannibal_corpse

https://mjml.io/try-it-live/components/hero/1

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question