【发布时间】:2021-01-25 02:28:45
【问题描述】:
我有两个并排的图像,我想使用 flexbox 制作相同的高度,并且我想对齐图像下方的文本。有人可以帮我吗??
这是我的代码:
.row{
display:flex;
}
.cell img{
width:150px;
}
<div class="content">
<div class="row">
<div class="cell">
<img src="https://hostingstudies.com/wp-content/uploads/2020/10/wordpress-589121_1280.jpg"></div>
<p class="project1info">
Featuring allows a user to search a musical artist and view a list of collaboraters they have worked with.</p>
<div class="cell">
<img src="https://hostingstudies.com/wp-content/uploads/2020/10/wordpress-1882120_1280-1.png"></div>
<p class="project1info">
Featuring allows a user to search a musical artist and view a list of collaboraters they have worked with.</p>
</div>
</div>
【问题讨论】:
-
请添加屏幕截图,在您的代码中图像高度相同!