vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   User title graphics: Hack needed? (https://vborg.vbsupport.ru/showthread.php?t=36801)

mjames 04-07-2002 08:19 PM

Chen, I just tried it again and couldn't get it to work. Let me explain what I did and you tell me if I did something wrong.

Firstly, I found:
Code:

$post[joindate]=vbdate($registereddateformat,$post[joindate]);
in functions.php and underneath it (no spaces), I added:
Code:

if ($post['usergroupid'] == 3 or $post['usergroupid'] == 5 or $post['usergroupid'] == 6) {
                        $post['userimage'] = '<img src="http://www.sports-central.org/community/boards/images/userimages/'.$post['usergroupid'].'.gif" border="0">';
                } else {
                        $post['userimage'] = '';
                }

I changed the usergroup IDs since the moderator group was different from the one you used. (Speaking of usergroups, apparently, like four or five of them have the same ID when I hovered my mouse over them. How can that be?)

I uploaded the images and made sure the images (3.gif, 6.gif, 7.gif) corresponded to the numbers in the code above. I then added this to the postbit template:
Code:

$post[userimage]
What happened was I think it worked for my administrators group as I had two of the same images under my name (the original one which I hand-coded in as well as the one from this hack). But I tried to remove the hand-coding HTML from the title of one of my moderators and no image showed up. Any ideas?

Admin 04-08-2002 12:42 PM

Are you sure 3 is the ID of your moderators group? If you have more than one (like SP has Mentors and stuff) you'll need to add that in the if statement.

And no, there's no way two usergroups have the same ID. Can't be. MySQL won't let that happen. :) View the HTML source / browser the 'usergroup' table in phpMyAdmin and you'll see the ID's.

mjames 04-24-2002 05:25 PM

Chen, I had to put this on the backburner for a while, but I got around to doing it today and it worked like a charm! I just wanted to say THANKS! I right-clicked on the URLs in my vB CP to find the IDs - two of them were strange (33 and 39), so I got it on the second try. :p

Admin 04-24-2002 05:57 PM

Glad it's working. :)

sunrunner_pei 11-12-2003 03:00 PM

Added to my forums. Works perfectly!!! Thanks!


All times are GMT. The time now is 07:59 AM.

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.01023 seconds
  • Memory Usage 1,723KB
  • 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
  • (3)bbcode_code_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (5)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
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete