Page 1 of 1

Getting rid of hyperlink underline

Posted: Wed May 29, 2024 5:20 am
by Portman
Hi,

I am assuming this is a really easy one...

I've created a modal link on a module I've created... the link is on a question circle.... but how I have done it there is a hyperlink undeline under the circle which looks really bad and I can't work out how to get rid of it....

the link is in the language file which may be the problem,

Code: Select all

 const MODULE_ORDER_TOTAL_AU_TOTAL_HEADING = 'Conversion into Australian Dollars <a href="#" role="button" class="card-link ml-0 border-bottom border-primary" data-toggle="modal" data-target="#CModal"><i class="fas fa-question-circle"></i></a>';
how do I fix this? Any help would be appreciated

Re: Getting rid of hyperlink underline

Posted: Wed May 29, 2024 5:49 am
by heatherbell
Portman wrote: Wed May 29, 2024 5:20 am how do I fix this?
Target the element that displays the link (which would be in the module file or tpl_ file, not the language file) with css in your user.css file text-decoration: none; or inline the style into the language constant, <a style ="text-decoration: none;", possibly style ="text-decoration: none !important;" might be necessary.

Re: Getting rid of hyperlink underline

Posted: Wed May 29, 2024 7:48 am
by burt

Re: Getting rid of hyperlink underline

Posted: Thu May 30, 2024 4:18 am
by Portman
thanks @heatherbell & @burt

I tried the inline method you suggested earlier, but with no luck, the solution Burt suggested though worked

Re: Getting rid of hyperlink underline

Posted: Thu May 30, 2024 6:16 am
by heatherbell
Portman wrote: Thu May 30, 2024 4:18 am I tried the inline method you suggested earlier, but with no luck
Strange because that is what that Bootstrap utility does:
Screenshot 2024-05-30 071436.png

Re: Getting rid of hyperlink underline

Posted: Thu May 30, 2024 11:53 pm
by Portman
yeah I thought it should work too , I tried a number of options in the inline method that you suggested and I just could not get it to work, but when I tried the bootstrap option it worked straight away... it is probably me and my lack of coding experience rather than the advice you gave.