News:

Wondering if this will always be free?  See why free is better.

Main Menu

member colors

Started by jimv8673, February 24, 2012, 03:11:20 PM

Previous topic - Next topic

jimv8673

Can anyone tell me where the code is that dictates the member colors??
What im trying to do is get the googlebot to show up in google colors where my colored member names are when they are online,

I have the code. its <span.style="color:(whatever color you want)>G=(whatever color)</span>

i believe this is the correct code i just dont know where it goes.

Thanks for the help, or if there is a better easier way to do this please by all means, suggest. :)

kat

Member colo(u)rs where? In the online list?

If so, we're having phun, with this very thing, here:

http://www.simplemachines.org/community/index.php?topic=469416.msg3281446#msg3281446

jimv8673

Hi  K@  :)

ive seen on many forums when the google bot shows up its in google colors, down where the members names are when they are online.

google just shows up white for me yukkk  a picky thing but i think the former looks cooler, im gonna look at that link you posted but if you have an answer for me or help please do.

jimv8673

Ok that mod shows the correct area, but google is not in the member group, and even if it was, i dont know how you would get that jumbled color, its not really a html color :)  and i dont have a problem with the other membergroups, just google.

kat

Ah! If it's just for googlebots, I guess there must be something in one of it's files which decides on that colour...

Lemme go have a butcher's, to see if I can see what it is...

I'm no coder, so this might take a while... ;)

jimv8673

Actually K  here is the code if i could just figure out where to put it, im guessing where ever google is in the template somewhere around the member groups would be my guess

<p>G<br /><span style="color: #ff0000;">o<br /></span><span style="color: #ffff00;">o<br /></span><span style="color: #0000ff;">g<br /></span><span style="color: #339966;">l<br /></span><span style="color: #ff0000;">e</span>&nbsp;</p>

kat

Bugger.

I forget which version of SMF you use, Jim.

kat

BoardIndex.template.php

Looks like the mod has these sections of code:

(empty($context['spiders']) ? '' : $context['num_spiders'] . ' ' . ($context['num_spiders'] == 1 ? $txt['ob_googlebot_spider'] : $txt['ob_googlebot_spiders']) . ', '),
$context['num_guests'], ' ', $context['num_guests'] == 1


and

', $txt[140], ':<br />', implode(', ', $context['list_users_online']);

if (!empty($context['spiders']))
{
if ($modSettings['ob_googlebot_display_own_list'])
echo '
<br />
', $txt['ob_googlebot_spiders_last_active'], ':<br />';
else
{
if (empty($context['users_online']))
echo '
', $txt[140], ':<br />';
else
echo ', ';
}

echo implode(', ', $context['spiders']);
}


Soooooo... I guess the bit you want to add goes in there, somewhere.

Sorry, but I can't give you more than that. :(

Backup the file and try a bit of trial-and-error?

jimv8673


kat

Bugger. The mod I'm looking at's only for v1.x.

* K@ goes for another look...

jimv8673

#10
id say youre close @k, but i dont see where the color code that its using now is in that anywhere  Hmmm
Thanks for all the help, if you hear anything on this issue or a fix, email me please  [email protected]
Thanks.  Like i say this is not a life or death situation, just one of the little annoyances, if you know what i mean.

kat

Hmmm... If I search the mod site for "Googlebot", I only get this one.

http://custom.simplemachines.org/mods/index.php?mod=143

:(

I removed your e-mail addy and saved it, so you don't get a spamfest. ;)

jimv8673

sweeet thanks, i get enough of that as it is.   ???

kat

No sweat!

As I'm getting the wrong mod, can you tell me which one you use?

jimv8673

Thats close again @K but if you look it displays, the bot in black, not various colors like google actually is

jimv8673

im not using a mod for that function, the member groups already display whatever color you choose in those settings, but all the bots are in white.  I know that has to be controlled somewhere, the code i posted above came from a html generator i found.
Im sure the codes are put in the template somewhere, to dictate say admin color, global Mod color, etc, and that is done auto by the membergroup editor, but bots are no member groups, and that control only allows one color anyway.

Do you ever wonder where i come up with these requests  LMAO.
anyway other boards do it so i know the much more intelligent Mods here can figure this out for me :)

kat

You may be right!

I suspect it's either in BoardIndex.php or Stats.

Not a clue, other than that.

:(

jimv8673

Ok i will weasel around, and maybe figure it out if not no biggy, maybe i can slip in to whatever forum that goes with a software that has that feature and trick them into telling me :)

kat

Good plan!

If you use the right browser, you might even be able to "Inspect element" and see the code.

Advertisement: