gpt4 book ai didi

html - 文本居中问题

转载 作者:太空宇宙 更新时间:2023-11-03 21:01:47 25 4
gpt4 key购买 nike

我有一个导航层,但我似乎无法获得指向其中中心的链接。

这是我正在使用的样式表

.Layer1 {
position:absolute;
width: 10%;
height: 95%;
list-style-position: outside;
list-style-type: disc;
background-color: #D2FFFF;
}
.Layer1 a {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 14px;
font-weight: 600;
color: #0066FF;
text-decoration: none;
text-align: center;
}

使用标准的 href 链接没有区别,指定样式为 href 也没有区别。我想知道我错过了什么。

最佳答案

你试过添加:

text-align: center;

到 .Layer1 {}?

关于html - 文本居中问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/532626/

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