Customizing SMF > Graphics and Templates
Changing the color of a partial text string
Sammy383:
Hello All,
Being a newbie, I think I posted my first question in the wrong board. Here it is again...
See the link below. This is what my login screen currently looks like. I'd like the text in the circle, which is now blue, to be a bright red color, or underlined, or something that makes it stand out. I am aware that the displayed color could be a setting on the user's browser ...
Any suggestions where/how to make this change?
K@:
The text, itself, is located in Themes/default/languages/Login.english.php:
--- Code: ---$txt['only_members_can_access'] = 'Only registered members are allowed to access this section.';
$txt['login_below'] = 'Please login below or';
$txt['register_an_account'] = 'register an account';
$txt['login_with_forum'] = 'with %1$s.';
--- End code ---
Normally, I believe that the colours of the text are controlled by index.css, which is in the theme's "css" directory.
That's where I get stuck...
Is there a way, perhaps, of defining a colour for a certain string, in the css file?
Sorry. That's not a lot of help, is it?
I'm hoping to inspire... ;)
cicka:
To color the area that you want find this part which has the language string posted by K@ at the Login.template.php file:
--- Code: ---', $txt['login_below'], ' <a href="', $scripturl, '?action=register">', $txt['register_an_account'], '</a> ', sprintf($txt['login_with_forum'], $context['forum_name_html_safe']), '
--- End code ---
and replace it with this:
--- Code: ---', $txt['login_below'], ' <a href="', $scripturl, '?action=register"><span style="color:red">', $txt['register_an_account'], '</span></a> ', sprintf($txt['login_with_forum'], $context['forum_name_html_safe']), '
--- End code ---
This will color that part in red as per your request.
K@:
Good stuff, Cicka!
cicka:
Glad to be of help :)
Navigation
[0] Message Index
[#] Next page
Go to full version