Support Forum

offline/online

SP SPQC
SPQC
Member

Would it be possible to have the ‘online’ text show up in color?  I know there already is an icon that do the job but just asking.

 

All I know is the line that handle this is :

 

sp_PostIndexUserStatus(‘tagClass=spCenter spPostUserStatus’, __sp(‘Online’), __sp(‘Offline’));

 

Maybe doing it this way ?

 

sp_PostIndexUserStatus(‘tagClass=spCenter spPostUserStatus’, __sp(‘Online&color=#ff0000’), __sp(‘Offline’));

 

Ok maybe not exactly, I’m not an expert.  wink

11 Answers

New Answer

YS Yellow Swordfish
Yellow Swordfish
Member

You need to look at the ‘spPostUserStatus’ class in the CSS file.
However, I do see we are not differentiating there between online and offline so I will open a ticket to see how easy that would be to add.

SP SPQC
SPQC
Member

I see in the changelog that something was done about this…  looking in the functions file I see onlineLabelClass but how to use it?

MP Mr Papa
Mr Papa
Member

add a new style and color it (or other) how you want…

span.spPostUserStatusOnline

SP SPQC
SPQC
Member

I add this the the custom styles of my WP theme or is there a way to define it to /styles/overlays/default.php?

MP Mr Papa
Mr Papa
Member

assuming you have your own sp theme, I would add it to that… the path you put is not valid… if you dont have your own sp theme, then yes, add it to your wp theme…

SP SPQC
SPQC
Member

I tried to add $spPostUserStatusOnline = ‘color: #FF0000’; as a test to my SP theme but nothing happen.  Sorry if I look dumb.

MP Mr Papa
Mr Papa
Member

that is not css… did you try to add it to the overlay??? it would need to be added to the theme… like

span.spPostUserStatusOnline { color: #ff0000;}

SP SPQC
SPQC
Member

Well I wanted to add it to S:P theme instead of the custom style from the WP theme, which is already having many lines I added it there to make change to how S:P look.  I don’t know if it’s the good place or ideal place to put all those styling changes but yet that’s what I did since it works.  I thought it would looks cleaner to move them in the S:P theme files.

 

Nevermind, I’ll do it that way.  It’s just one more line… wink Thanks.

MP Mr Papa
Mr Papa
Member

it would be… but are you confusing theme css file with the overlay? I was suggesting adding it to, for example, wp-content/sp-resources/forum-themes/default/styles/default.php… not the overlay file… and of course, in your theme main style file…

if you are using a stock sp theme, then the wp theme is the place to put it… but if your own sp theme, then put it there…

SP SPQC
SPQC
Member

Ha!  There you go.  Yes was confusing both…  geesh. embarassed Thanks!  Now I can move all the extra styling from the WP theme custom includes to wp-content/sp-resources/forum-themes/default/styles/default.php

MP Mr Papa
Mr Papa
Member

BUT that looks like our default theme… if you modify our default theme, you will LOSE your changes on update since the wp updater removes the existing one before grabbing the new one…

you really need to make your own theme… start by copying our theme… here is some help:

http://codex.simple-press.com/codex/themes/theme-basics/creating-a-theme/