Solved

How to remove underline on a hyperlink in Craft Theme

CaptBret
Excursionist
34 0 16

I would like to remove the underlines from on page hyperlinks.  I'd like to remove both the constant underline and the hover underline.  The hyperlinks are on various pages, not the header or footer. 

 

I have tried several code edits that were suggested in previous posts, but nothing has worked so far.

 

This is code suggested a few times to be added to the liquid or base file but it didn't work for me.

a {
text-decoration: none !important;
}

 

Any help would be greatly appreciated!

 

Accepted Solution (1)

topnewyork
Navigator
298 34 45

This is an accepted solution.

Hi @CaptBret 

Follow these Steps:
Go to Online Store Edit Code Find theme.liquid file 
Add the following code in the bottom of the file above </body> tag

{% style %}
a {
    text-decoration: none;
}
{% endstyle %}

topnewyork_0-1696517566171.png

If I managed to help you then, don't forget to Like it and Mark it as Solutions.

 

Need a Shopify developer?
Hire us at topnewyorkwebdesign.com
For Shopify Design Changes | Shopify Custom Coding | Custom Modifications
Subscribe to our youtube channel

View solution in original post

Replies 10 (10)

topnewyork
Navigator
298 34 45

@CaptBret Would you mind to share your store URL website, with password if its protected? Thanks!

Need a Shopify developer?
Hire us at topnewyorkwebdesign.com
For Shopify Design Changes | Shopify Custom Coding | Custom Modifications
Subscribe to our youtube channel
CaptBret
Excursionist
34 0 16
topnewyork
Navigator
298 34 45

@CaptBret can you share the screenshot where you are facing the issue?

Need a Shopify developer?
Hire us at topnewyorkwebdesign.com
For Shopify Design Changes | Shopify Custom Coding | Custom Modifications
Subscribe to our youtube channel
CaptBret
Excursionist
34 0 16

These are on a collection page.  The text that is underlined has hyperlinks.  I have not added hyperlinks to the rest yet. 2023-10-5.JPG

topnewyork
Navigator
298 34 45

@CaptBret please share the page link.

Need a Shopify developer?
Hire us at topnewyorkwebdesign.com
For Shopify Design Changes | Shopify Custom Coding | Custom Modifications
Subscribe to our youtube channel
Made4uo-Ribe
Shopify Partner
6381 1532 1902

Hi @CaptBret 

Where we can find this page? We check ypour page but couldnt find the page that you like to remove the underline. Can you share it with us. Thanks!

If this fixed your issue Likes and Accept as Solution is highly appreciated. Coffee tips fuels my dedication.
Get EXPERIENCED Shopify developers at affordable rates—visit Made4Uo.com for quick quote!
Do not lost your Shopify store! Get FREE trial with ✔️ Rewind Backup: Automatic, reliable, stress-free.

topnewyork
Navigator
298 34 45

This is an accepted solution.

Hi @CaptBret 

Follow these Steps:
Go to Online Store Edit Code Find theme.liquid file 
Add the following code in the bottom of the file above </body> tag

{% style %}
a {
    text-decoration: none;
}
{% endstyle %}

topnewyork_0-1696517566171.png

If I managed to help you then, don't forget to Like it and Mark it as Solutions.

 

Need a Shopify developer?
Hire us at topnewyorkwebdesign.com
For Shopify Design Changes | Shopify Custom Coding | Custom Modifications
Subscribe to our youtube channel
CaptBret
Excursionist
34 0 16

Thank you, this worked perfectly.  I apologize for the delayed reply, shopify blocked my messages as spam.  Apparently we were working too quickly and I sent too many messages. 

Kodamo
Excursionist
29 0 6

Hi I have tried this today and it's not working. Is there an updated code needed? Thank you!