How do I disable link underlines in confluence 4.2?

I've just started down the path of 3.5 -> 4.2 and am having one heck of a time getting the migration going.

One that's bugging me is the underscores on all the page links. I can't figure out how to turn them off, and on the Atlassian wiki it does not appear to be on.

I can confirm that this is coming from CONF_INST/confluence/includes/css/wiki-content.css:125-129 with the following content:

.wiki-content a,
.wiki-content a:link,
.wiki-content a:visited {
    text-decoration: underline;
}

Now I could quite simply edit this stylesheet (and wiki-content-min.css) to correct this, though I'd like a proper solution that I don't have to remember to apply whenever I update Confluence.

I've tried overriding this style in the spaces stylesheet and the global stylesheet with no luck.

Confluence 4.x really is driving me up the wall.

2 answers

1 accepted

Hallo Brett

Are you using the Documentation theme in your space? If so, then this bug is the cause of your problems:

https://jira.atlassian.com/browse/CONF-24543

To fix it, you can apply a CSS style via the Space Admin screen. You need System Administrator permissions, even though you're using the space admin screens. Choose 'Browse' > 'Space Admin', then click 'Stylesheet' in the left-hand menu (under 'Look and Feel'). Also note that this option may be disabled on your site. See the docs:

http://confluence.atlassian.com/display/DOC/Styling+Confluence+with+CSS

Once you've got the Stylesheet screen open, you can enter the folllowing CSS to remove the underlines (assuming you're using the Documentation theme):

.wiki-content a:link, .wiki-content a:visited, .wiki-content a:active {
    text-decoration: none;
}
 
.wiki-content a:hover {
    text-decoration: underline;
}

I hope this solves the problem!

Cheers, Sarah

Thanks Sarah, it appears this does resolve the issue though I'm not using the documentation theme, I did try this originally though it was seeminly ignored, I guess it must have been my browser cache.

With 61 spaces and counting this is a workaround rather than a solution as it would be a pain to maintain.

We already have just shy of 280 lines of CSS to each space which is becoming troublesome to maintain, this is just to make the spaces look "right".

Sarah, I've marked this as accepted as the work-around does work, however I'd like to see something applied properly to turn this on/off as confluence should not be underlining all links IMHO, if anything that should be something a site admin should be able to decide on without needing to update the CSS sheets each time an upgrade occurs.

Hi, is there a (reason I can't/a way that I can) make this change in the Theme's Stylesheet? We have a lot of Spaces and I don't want to hack Stylesheets for all of them.

It is annoying and frustrating, though no reason has been given to me. It's one of the painful points of performing a confluence upgrade that I must remember to go hack the stylesheets and hope that nothing else popped up (new classes etc).

Suggest an answer

Log in or Sign up to answer
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Kesha Thillainayagam
Posted Apr 13, 2018 in Confluence

We want to hear how your non-technical teams are using Confluence!

Hi Community! Kesha (kay-sha) from the Confluence marketing team here! Can you share stories with us on how your non-technical (think Marketing, Sales, HR, legal, etc.) teams are using Confluen...

345 views 20 10
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you