Simple Machines Community Forum

Customizing SMF => SMF Coding Discussion => Topic started by: danshell on October 29, 2014, 09:31:04 PM

Title: I need Links in Posts to be bold or a different colour
Post by: danshell on October 29, 2014, 09:31:04 PM
Hi There
I am trying to make any links in posts appear different to the normal text so its obvious they are links.

I can edit it in the .css file but that is also changing every link on the site, including all my menus etc.

Is there a way to make just the links in post appear different?

Sorry if its a newbie question.
Title: Re: I need Links in Posts to be bold or a different colour
Post by: JBlaze on October 30, 2014, 12:04:48 AM
Open your current theme's index.css file, and find this:

/* Styling for BBC tags */
.bbc_link:link, .bbc_link:visited
{
border-bottom: 1px solid #A8B6CF;
}
.bbc_link:hover
{
text-decoration: none;
border-bottom: 1px solid #346;
}


You can change the hexcodes for the colors you'd like link to be. .bbc_link:link and .bbc_link:visited are the color you want the link to be normally, while .bbc_link:hover is the color you want the link to be when hovering over it with the cursor.

To get the hex color codes you want, simply Google "hex color codes" (https://www.google.com/search?q=hex-color-codes) and many resources should be returned to help you select which colors you'd like.

Remember to do a hard refresh (press CTRL + F5) in your browser after making modifications to your css files to see the changes if they don't appear right away.
Title: Re: I need Links in Posts to be bold or a different colour
Post by: danshell on October 30, 2014, 08:44:51 AM
Quote from: zilladotexe on October 30, 2014, 12:04:48 AM
Open your current theme's index.css file, and find this:

/* Styling for BBC tags */
.bbc_link:link, .bbc_link:visited
{
border-bottom: 1px solid #A8B6CF;
}
.bbc_link:hover
{
text-decoration: none;
border-bottom: 1px solid #346;
}


You can change the hexcodes for the colors you'd like link to be. .bbc_link:link and .bbc_link:visited are the color you want the link to be normally, while .bbc_link:hover is the color you want the link to be when hovering over it with the cursor.

To get the hex color codes you want, simply Google "hex color codes" (https://www.google.com/search?q=hex-color-codes) and many resources should be returned to help you select which colors you'd like.

Remember to do a hard refresh (press CTRL + F5) in your browser after making modifications to your css files to see the changes if they don't appear right away.


You are a genius :) Thank you very much that sorted my problem.
Title: Re: I need Links in Posts to be bold or a different colour
Post by: JBlaze on October 30, 2014, 09:00:14 AM
Glad to help! I'll go ahead and mark this solved :)