vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Member Archives (https://vborg.vbsupport.ru/forumdisplay.php?f=202)
-   -   Recoloring the "user online" links (https://vborg.vbsupport.ru/showthread.php?t=33805)

Simon Moon 01-05-2002 04:05 AM

I am trying to recolor the user online links. For this i need to edit index.php 2 times before this comes in place:
PHP Code:

eval("\$activeusers .= \", ".gettemplate('forumhome_loggedinuser')."\";"); 

I make the coloring depending on status. The higher rank you have, the stronger is your color. Anyways, thats not my problem at all. The real bummer is, that i cant seem to change the links color. I wanted to define an CSS style in the head part, for each of the levels, and then assign the CSS to the links.
This is how my forumhome_loggedinuser template looks like now
Code:

<a href="member.php?s=$session[sessionhash]&action=getinfo&userid=$userid"
 class="$usercolor_class">$username</a>$invisibleuser

now in the code in index.php i define $usercolor_class to be the name of the class.
if these are my styles:
.level_1 {
COLOR: #666666;
}
.level_2 {
COLOR: #888888;
}
i would assign "level_1" or "leve_2" to the $usercolor_class variable. It wont change the color at all, no matter what i do. So anyone got an idea what i could be doing wrong? I am sure its something simple, but i cant find the error.

Gimp 01-05-2002 04:50 PM

PHP Code:

      if ($loggedin['usergroupid'] == and $highlightadmin) {
          
$username "<b><i>$loggedin[username]</i></b>";
      } else if ((
$mod["$userid"] or $loggedin['usergroupid'] == 5) and $highlightadmin) {
          
$username "<b>$loggedin[username]</b>";
      } else {
        
$username $loggedin['username'];
      } 

look in the index.php file for this and change it as like it fits ur needs no need to change the CSS or anything like that only the code

Gimp 01-05-2002 04:56 PM

i think there was a hack like this though

Simon Moon 01-05-2002 10:28 PM

Hi

This is standard in 2.2.1, but this is now what i am looking for. I want to recolor the links, but they DONT accept my recoloring at all. I want to recolor certain levels and the code is celar, but the CSS doesn seem to work. I checked it, my code works, so far, that it gets assigned to the links, but then my CSS doesnt work on those things. I have no clue why, so please, can anyone help me?

Gimp 01-09-2002 04:45 PM

well u need a CSS program to do the job for you

Simon Moon 01-09-2002 04:48 PM

Thanks, but teh solution is much simpler. make a variable for the color, and let it change in the index.php to an hex value you want it to have. Then change the "loggedinuser" template, by packing around the username a <font color="$user_color">username</font> and that will do the trick. Its not the nicest way, but at least one that works :)

Moonwolf 01-09-2002 05:39 PM

You might want to check out the hack at https://vborg.vbsupport.ru/showthrea...hreadid=32149, it might help point you in the right direction, if it isn't the solution you need.

Kathi

Dade 01-09-2002 08:55 PM

Thanks Wolf :)


All times are GMT. The time now is 03:23 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01027 seconds
  • Memory Usage 1,730KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_code_printable
  • (2)bbcode_php_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (8)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete