Efficient Trade Ltd Efficient Trade Ltd - 4 months ago 30
CSS Question

Make hyperlink underline appear on mouseover (currently the opposite)

I am wanting to imitate this website, which only underlines a hyperlink once the user hovers over the link.

Currently in my Magento store, any hyperlinks are already underlined before the user hovers over it & when the user does hover over the link, the underline is removed.

So basically, I want the very opposite of what is happening.

I am using Modern theme f001. Can anyone explain how I could go about changing this?


You need to change in the CSS file of your theme:


Line 1178:

a {
   color: #1E7EC8;
   text-decoration: none; // changed from text-decoration:underline

Line 131

a:hover {
   text-decoration: underline; // changed from text:decoration:none

Please note that the line numbers might be wrong and you might need to search for the a class definition in the CSS file in order to change them.