如何将元素放置在另一个元素的顶部,而不使用位置和边距? [英] How to position an element on top of another element without using position and margin?

查看:267
本文介绍了如何将元素放置在另一个元素的顶部,而不使用位置和边距?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这是我的代码:

<table>...Some content...</table>
<table>...Another content...</table>

我想将第二个表放在第一个表的顶部。

I want to put the second table on top of the first table. This is to be used as an email template (in some clients position and margin are not available).

推荐答案

这是唯一的电子邮件模板两个选项可用( transform 之外,如果 position 不可用,肯定不会工作)一个元素侵入另一个元素的空间。如果你不能使用 position margin ,那么你运气不好,评估你正在尝试实现什么以及为什么。任何机会,你可以用图像做这个?

Those are the only two options available (outside of transform, which definitely won't work if position isn't available) that will allow one element to invade another element's space. If you can't use position or margin, then you're out of luck, and you need to re-evaluate what you are trying to achieve and why. Any chance you could do this with images?

这篇关于如何将元素放置在另一个元素的顶部,而不使用位置和边距?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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