CSS更改标签的字体颜色(在span.text-inner之前和之后)

问题描述 投票:-1回答:2

需要帮助将自定义字体颜色添加到CSS中的表单标签到WordPress网站。我尝试使用大多数selectors添加新的风格并且没有成功,似乎有些事情超越了它。网站:reliableconcreting.com.au

See screenshot

When changing the color as per answers below it turns orange

在浏览器中工作而不是在子css表中:

body[data-form-style="minimal"] .minimal-form-input label span.text .text-inner     {
    color: #000000!important;
    display: inline-block;
}
javascript jquery css wordpress
2个回答
0
投票

您可以在颜色声明后使用!important来覆盖任何默认颜色。

.text-inner {
     color: "yourColor" !important;
}

0
投票

重要声明将使用正常声明覆盖作者规则。

p{
color: red !important;
}
p{
color: blue;
}
<p>This is some text.</p>

即使我在第一个重要规则将被加权并且用作第一优先权之后写出新规则。

© www.soinside.com 2019 - 2024. All rights reserved.