我正在制作一个测试登录页面并使用重力表单进行注册,我的问题是当表单在完成后自动调整大小(只为确认消息留出空间)时,它会向上推其下方的元素并破坏布局。我确定它是一个简单的解决方案,但我似乎找不到它。代码结构:
<h3 style="line-height: 15px;">SOME TEXT</h3>
<h3>MORE TEXT</h3>
<h3 style="line-height: 15px;">MORE TEXT</h3>
<h4>MORE TEXT</h4>
<img class="alignnone size-full wp-image-492" style="position: absolute; top: 430px; left: 80px;" src="image.png"width="350" height="202" /></a>
<div style="width: 40%;
background-color: #ffce32;
border: 3px solid #8E0F0F;
position: relative; bottom: 180px; left: 610px;
padding: 10px; border-radius:20px;">[my gravity form]</div>
<div style="position: relative; bottom: 160px;">
<h4 style="text-align: center;">TEXT</h4>
<img>
<h4 style="text-align: center;">TEXT</h4>
<div class="my_gallery" style="margin-left: 110px;"></div>
<h4 style="text-align: center;">TEXT</h4>
<p>TEXT</p>
<h4 style="text-align: center;">TEXT</h4>
</div>
问题在于表单正下方的 div 被向上推并在表单缩小时破坏了布局。