【发布时间】:2019-05-24 02:48:34
【问题描述】:
我正在尝试创建一个标题图像,其中一些文本位于图像的底部。但是,每次我创建行和列时,文本都会转到另一行。问题是我正在尝试创建一个包含两个文本实例的标题图像。我弄乱了绝对位置,这也不起作用。我也尝试过弄乱 d-flex 属性、对齐项目结束和对齐内容......
我知道这很容易解决,我只是想弄清楚如何让文本显示在底部。
那么,作为示例,您将如何创建下面的图像?
<div class="fluid-container" style="width: 100%">
<div class="row" style="">
<div class="col"> <img class="card-img-top" src="images/electrical-repair.png" width="100%" height="auto" alt=""/>
<h4 class="text-danger d-flex justify-content-center bannerText text-center">Premiere Commercial Electrical Services in the Northwest</h4>
</div>
</div>
【问题讨论】:
标签: html css twitter-bootstrap bootstrap-4