谷歌浏览器与设置:访问CSS属性有问题吗? [英] Does google chrome has issue with setting a:visited css properties?
问题描述
只想知道有没有人有和我一样的问题。基本上,我无法将访问超链接的背景颜色设置为不同的背景颜色。
这是Google Chrome的一个已知问题吗?我看到有人用背景图像提出类似的问题。设置颜色属性似乎工作正常。
这是我使用的代码:
a:visited {
background-color:red;
}
任何信息将不胜感激。
亲切的问候,
Andrew
改为使用以下内容:
$ b
a {
background-color:white;
}
a:visited {
background-color:red;
$ b为了安全起见,非常严格地限制了使用:visited选择器可以做什么。
Just want to find out if anyone out there is also having the same issue as i am. Basically, I am unable to set the background color for a visited hyperlink to different background-color.
Is this a known issue for Google Chrome? I have seen people raising similar issue with background-image. setting the color attribute seems to be working fine.
this is the code that i used:
a:visited{
background-color: red;
}
Any information would be appreciated.
Kind Regards,
Andrew
解决方案 Instead, use the following:
a {
background-color: white;
}
a:visited{
background-color: red;
}
For security reasons -- specifically, in order to prevent history sniffing -- Chrome limits very strictly what can be done using the :visited selector.
这篇关于谷歌浏览器与设置:访问CSS属性有问题吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!