Set visited link color to whatever the color of un-visited link is (P.S. not the usual question)

前端 未结 10 1767
执念已碎
执念已碎 2021-02-03 16:59

I need to set the a:visited CSS to whatever color the normal a is set to.

What I want to be able to tell the browser is, for the visited links, use the same

10条回答
  •  孤独总比滥情好
    2021-02-03 17:44

    a:link{color:inherit}
    a:active{color:inherit}
    a:visited{color:inherit}
    a:hover{color:inherit}
    

    Hell yes.

    I needed this because some text links (as opposed to image links) were a major part of my project's main menu, so I want them MY colours, not browser colours!

    Each link was enclosed in a p tag group whose class had a particular colour (MY colour) set in CSS.

提交回复
热议问题