这是源码地址:
https://github.com/349989153/h5Practice/blob/master/login.html
可以在 http://htmlpreview.github.io 上直接预览此html文件。
我的问题是:
请注意观察源码的6,26,31行。
为了不被a标签的默认样式(下划线以及字体颜色深蓝)影响,我写了第6行的css。
但是只有第31行的a标签受到了text-decoration的影响,
第26行没有被影响到。
在chrome中查看element的时候可以看到第26行的样式是
Inherited from a:
user agent stylesheet a:-webkit-any-link {
color: -webkit-link;
cursor: auto;
}
为什么 text-decoration:none 影响不到第26行?怎么解决?
兄弟,你说第26行没有被影响到,是不是显卡出了问题..
css
a:hover { text-decoration: none; }