gpt4 book ai didi

css - 创建 5 个等高的列

转载 作者:行者123 更新时间:2023-11-28 16:47:01 24 4
gpt4 key购买 nike

<分区>

我有几个使用 bootstrap 创建的列作为页脚。每列都有一些信息(即:地址、链接等)。但是其中包含的信息比另一列更多的列会更长,因此所有列都不会均匀排列。我该如何解决这个问题?

我的页脚:

<div class="row row-centered">
<div class="col-md-2 col-centered col-centered">
<!-- Address -->
<div class="" style="padding-right:0">
<div class="contact-item">
<div class="ci-icon">
<i class="fa fa-building-o"></i>
</div>
<div class="ci-title font-alt">
Markten
</div>
<div class="ci-text">
Website B.V.<br>
Overkampsweg 16a<br>
8102 PH Raalte
</div>
</div>
</div>
<!-- End Address -->
</div>
<div class="col-md-2 col-centered">
<!-- Address -->
<div class="" style="padding-right:0">
<div class="contact-item">
<div class="ci-icon">
<i class="fa fa-cube"></i>
</div>
<div class="ci-title font-alt">
Producten
</div>
<div class="ci-text">
<a href="http://www.website.nl/filtering.html">Filtering</a><br>
<a href="http://www.website.nl/toebehoren.html">Toebehoren</a><br>
<a href="http://wwww.website.nl/zacht.html">Zacht</a>
<a href="http://www.website.nl/hard.html">Hard</a>
<a href="http://www.website.nl/technische-gegevens.html">Technische gegevens</a>
</div>
</div>
</div>
<!-- End Address -->
</div>
<div class="col-md-2 col-centered">
<!-- Address -->
<div class="" style="padding-right:0">
<div class="contact-item">
<div class="ci-icon">
<i class="fa fa-check"></i>
</div>
<div class="ci-title font-alt">
Diensten
</div>
<div class="ci-text">
Website B.V.<br>
Overkampsweg 16a<br>
8102 PH Raalte
</div>
</div>
</div>
<!-- End Address -->
</div>
<div class="col-md-2 col-centered">
<!-- Address -->
<div class="" style="padding-right:0">
<div class="contact-item">
<div class="ci-icon">
<i class="fa fa-external-link"></i>
</div>
<div class="ci-title font-alt">
Links
</div>
<div class="ci-text">
Link 1<br>
Link 2<br>
Link 3
</div>
</div>
</div>
<!-- End Address -->
</div>
<div class="col-md-2 col-centered">
<!-- Address -->
<div class="" style="padding-right:0">
<div class="contact-item">
<div class="ci-icon">
<i class="fa fa-map-marker"></i>
</div>
<div class="ci-title font-alt">
Adresgegevens
</div>
<div class="ci-text">
Website B.V.<br>
Overkampsweg 16a<br>
8102 PH Raalte
</div>
</div>
</div>
<!-- End Address -->
</div>
</div>

使用 CSS:

/* centered columns styles */
.row-centered {
text-align:center;
}
.col-centered {
display:inline-block;
float:none;
/* reset the text-align */
text-align:left;
/* inline-block space fix */
margin-right:-4px;
}

.row-centered {
text-align: center;
margin-bottom: 40px;
}

Jsfiddle:

https://jsfiddle.net/L7L8dryd/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com