gpt4 book ai didi

php - 写在中心

转载 作者:太空宇宙 更新时间:2023-11-04 00:12:37 26 4
gpt4 key购买 nike

我用这段代码写在中心:

echo "<div class='pagination' align ='center'>";

但它仍然显示在左侧。我如何在中心书写。

此外,这些是 css 中的分页代码:

    <div class='pagination' text-align:center>
<span class='current'>1</span>
</div>
.pagination {
clear:both;
padding:20px 0;
position: relative;
font-size:11px;
line-height:13px;
}

.pagination span, .pagination a {
display:block;
float: left;
margin: 2px 2px 2px 0;
padding:6px 9px 5px 9px;
text-decoration:none;
width:auto;
color:#fff;
background: #555;
}

.pagination a:hover{
color:#fff;
background: #3279BB;
}

.pagination .current{
padding:6px 9px 5px 9px;
background: #3279BB;
color:#fff;
}

最佳答案

尝试这样的事情

.pagination span, .pagination a {
background: none repeat scroll 0 0 #555555;
color: #FFFFFF;
display: inline-block;
margin: 2px 2px 2px 0;
padding: 6px 9px 5px;
text-decoration: none;
width: auto;
}

.pagination {
clear:both;
padding:20px 0;
position: relative;
font-size:11px;
line-height:13px;
text-align:center;
}

关于php - 写在中心,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/12526042/

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