我刚刚开始使用FontAwesome,到目前为止一直很好.但是有一个问题,当我使用锚标签并且它有text-decoration:none,并且悬停时text-decoration:underline.当我悬停链接时,图标也会获得下划线效果...我如何只获得带下划线的链接,而不是图标?
我试图将它放在锚标记之外,但它没有得到我分配给链接的颜色
示例代码:
<style>
a{color:red;text-decoration:none;}
a:hover{text-decoration:underline;}
</style>
<a href="#"><span class="fa fa-camera-retro"> </span>This's a test</a>
Run Code Online (Sandbox Code Playgroud)
谢谢