News:

SMF 2.1.4 has been released! Take it for a spin! Read more.

Main Menu

Change Font Color and more?

Started by skidzGλMING, May 04, 2018, 07:30:19 PM

Previous topic - Next topic

skidzGλMING

Can someone explain me How to change font color, i mean general change
showed in img.
I'm using theme DarkDream.

GigaWatt

Well, that's how you do it... or you could use BBCode directly (not relying on the WYSIWYG editor).

EDIT: You mean as a general setting, on the whole forum?
"This is really a generic concept about human thinking - when faced with large tasks we're naturally inclined to try to break them down into a bunch of smaller tasks that together make up the whole."

"A 500 error loosely translates to the webserver saying, "WTF?"..."

skidzGλMING

Quote from: GigaWatt on May 04, 2018, 09:58:21 PM
EDIT: You mean as a general setting, on the whole forum?

i mean like change this dropdown, blue to something different color, and change brown, teal and navy colors to different colors.
So when i'm posting new post, i want my personal colors to be shown in dropdown... like how to change current color dropdown list?

GigaWatt

If you only want to change the text of the selected color, just change the translation of the color in your language ;). For example, "Red" can be "Fire" ;).
"This is really a generic concept about human thinking - when faced with large tasks we're naturally inclined to try to break them down into a bunch of smaller tasks that together make up the whole."

"A 500 error loosely translates to the webserver saying, "WTF?"..."

Pipke

in ../default/GenericControls.template.php

Code (find) Select

// Print a drop down list for all the colors we allow!
if (!isset($context['disabled_tags']['color']))
echo ',
{
sType: \'select\',
sName: \'sel_color\',
oOptions: {
\'\': ', JavaScriptEscape($txt['change_color']), ',
\'black\': ', JavaScriptEscape($txt['black']), ',
\'red\': ', JavaScriptEscape($txt['red']), ',
\'yellow\': ', JavaScriptEscape($txt['yellow']), ',
\'pink\': ', JavaScriptEscape($txt['pink']), ',
\'green\': ', JavaScriptEscape($txt['green']), ',
\'orange\': ', JavaScriptEscape($txt['orange']), ',
\'purple\': ', JavaScriptEscape($txt['purple']), ',
\'blue\': ', JavaScriptEscape($txt['blue']), ',
\'beige\': ', JavaScriptEscape($txt['beige']), ',
\'brown\': ', JavaScriptEscape($txt['brown']), ',
\'teal\': ', JavaScriptEscape($txt['teal']), ',
\'navy\': ', JavaScriptEscape($txt['navy']), ',
\'maroon\': ', JavaScriptEscape($txt['maroon']), ',
\'limegreen\': ', JavaScriptEscape($txt['lime_green']), ',
\'white\': ', JavaScriptEscape($txt['white']), '
}
}';


like if you want to change color white:
Code (find) Select

\'white\': ', JavaScriptEscape($txt['white']), '


to the color Turquoise: (all color names you can use can be found here)
Code (replace) Select

\'turquoise\': ', JavaScriptEscape($txt['turquoise']), '


then add 'your new' text string to ../default/languages/Post.english.php
like this:
Code (add) Select

$txt['turquoise'] = 'Turquoise';
]

good luck with the edits ;)
"If something is wrong, fix it if you can. But train yourself not to worry: Worry never fixes anything."

Click here to view my mods for SMF

Hey 👋 Did i helped... you like what i do. You can now buy me a coffee! ☕

Advertisement: