All things Shopify and commerce
We're moving the community! Starting July 7, the current community will be read-only for approx. 2 weeks. You can browse content, but posting will be temporarily unavailable. Learn more
Hi, I want to remove underline's when linking a word to another page. I've tried different codes already on this forum, but none of them seems to work for me.
Hey @FrisoPi ,
To remove the underline from links, try adding this CSS rule:
a {
text-decoration: none;
}
This will apply to all <a> tags on your page. If you want it to apply only to certain links, you could use a class:
<a href="your-link" class="no-underline">Your Text</a>
Then add the CSS:
.no-underline {
text-decoration: none;
}
Let me know if this works for you!
If I was able to help you, please don't forget to Like and mark it as the Solution!
Best Regard,
Rajat Sharma
Doesn't work..
Could you share your store URL so I can check?
thanks
Just found the solution:
<style>
.link, .prose a:not(.button) {
background-size: 0 1px;
}
.link:hover, .prose a:not(.button):hover {
background: linear-gradient(to right, currentColor, currentColor) 0 min(100%, 1.35em) / 100% 1px no-repeat;
}
</style>
This worked for me.
Great find! That CSS approach is a nice way to keep links styled subtly without the underline, while adding a hover effect. Let me know if you need any further adjustments!