MyBB Community Forums

Full Version: Control Link Color in Messages
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
The stock MyBB uses the same CSS code to color the links on the index page and in messages (other places too). Suppose you want to use Internet standard colors for messages (or colors of your own choice), while leaving other parts of the interface as is. Here's how to do it:

Step 1
In your admin control panel, select the theme you want to edit. Open its global.css. Click on Edit Stylesheet: Advance Mode. You will see a window called "Full Stylesheet for global.css." In that window locate:

.post_body {
	padding: 5px;
}


Add after it:

.post_body a:link {
	color: #0000ff;
	text-decoration: underline;
}

.post_body a:visited {
	color: #800080;
	text-decoration: underline;
}

.post_body a:hover, .post_body a:active {
	color: #ff0000;
	text-decoration: underline;
}

Then click the button below the window that says "Save Changes."

Once this is added you can change these to any colors you want. To learn more about this, search the Internet for info about hex color codes.

Step 2 (might not be necessary with latest version)
Because of a bug in the ver. 1.6.1 postbit_classic template, it cannot accept post_body styling. If you are experiencing this problem with the classic postbit, open the postbit_classic template and find:

<div id="pid_{$post['pid']}" style="padding: 5px 0 5px 0;">

replace with:

<div id="pid_{$post['pid']}" class="post_body" style="padding: 5px 0 5px 0;">.

Credit goes to MattRogowski for locating this bug and providing the fix.
good work..