我到处寻找解决方案但没找到任何东西......
我在HTML5页面中有这段代码
<div>
<p class="title_paragraph">
<a id="title" href="http://www.milanochamberorchestra.com">Milano Chamber Orchestra</a>
</p>
</div>
CSS
.title_paragraph {
color: #f89938;
text-align: center;
text-shadow: 0 0 12px rgba(230,160,55,0.6);
font-family: 'Buda', cursive;
font-weight: 100;
font-size: 46px;
z-index: 0;
position: relative;
}
#title:link {text-decoration:none;}
#title:visited {text-decoration:none;}
#title:hover {text-decoration:none;}
#title:active {text-decoration:none;}
为什么链接没有以正确的颜色显示?它必须是黄色/橙色,而不是紫色!
答案 0 :(得分:3)
试试这个
.title_paragraph a{
color: #f89938;
text-align: center;
text-shadow: 0 0 12px rgba(230,160,55,0.6);
font-family: 'Buda', cursive;
font-weight: 100;
font-size: 46px;
z-index: 0;
position: relative;
}
#title:link {text-decoration:none;}
#title:visited {text-decoration:none;}
#title:hover {text-decoration:none;}
#title:active {text-decoration:none;}
答案 1 :(得分:0)
对我而言,您的浏览器似乎正在显示“访问过的链接”的链接样式,因为您已经点击了该链接。您还可以通过清理浏览器缓存来验证这一点。 Visited Links Selector应该可以解决您的问题。