vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   Staff Icon in Postbit (https://vborg.vbsupport.ru/showthread.php?t=74403)

AnhTuanCool 01-31-2005 08:53 PM

Make a new custom profile field with Single-Selection Radio Buttons as field type.
It will display an option in Edit Option section in UserCP(take a look at the attachment) and $post[field5](5 as your field id) with contain the user's value...if you want it more detail, just ask ;)

MR-2ZZ 02-05-2005 09:17 AM

<a href="http://www.driftchat.com/forum/showthread.php?p=190#post190" target="_blank">http://www.driftchat.com/forum/showt...?p=190#post190</a>

All I did was added user ranks. As stated above with a simple template mod you can just add a single line text, use HTML, put the phrase in your template and viola!

Allan 02-05-2005 09:34 AM

Thank You :)

Goog job !

djjeffa 02-20-2005 07:36 PM

this is pretty cool i just set it up to work with my admins but im tring to set it for dirent pic for diffrent groups can anyone help me cause im using the rank par for post count bar the more they post the father it goes.

MikaK 02-27-2005 08:12 AM

Quote:

Originally Posted by AnhTuanCool
Make a new custom profile field with Single-Selection Radio Buttons as field type.
It will display an option in Edit Option section in UserCP(take a look at the attachment) and $post[field5](5 as your field id) with contain the user's value...if you want it more detail, just ask ;)

Thanks AnhTuanCool. Where in your code should I place the $post[field16] as mine is set currently for field id:16?

Regards,
-Mika

Bulleh 03-01-2005 09:58 PM

im getting errors from the psd....strange
*ignore above*

Got Hack Working
*INSTALLED*

djjeffa 03-12-2005 08:51 PM

Quote:

Originally Posted by djjeffa
this is pretty cool i just set it up to work with my admins but im tring to set it for diffrent pic for diffrent groups can anyone help me cause im using the rank par for post count bar the more they post the father it goes.

bump?

Rampag33 03-14-2005 03:52 PM

Install, thx, work with no problem.

be good to have it diffrent pics for diffrent ranks tho.

bkaul 03-16-2005 02:36 AM

Not hard to do - create separate icons, and separate templates for each group - here, we'll have admins, mods, and other staff:

In functions_showthread.php, add the following instead of just what's in the instructions:
PHP Code:

// Icon Staff Hack by AnhTuanCool
        // modified by bkaul for multiple icons
        // get icon staff represent img and titles
        
$adminusergroupids = array('6');
        
$modusergroupids = array('5','7');
        
$staffusergroupids = array('30'); // your array of staff usergroupid
        
if (in_array($post['usergroupid'], $adminusergroupids))
        {
           eval(
'$post[\'iconstaff\'] .= "' fetch_template('postbit_iconadmin'). '";');
        }
        else
        {
            if (
in_array($post['usergroupid'], $modusergroupids))
            {
               eval(
'$post[\'iconstaff\'] .= "' .fetch_template('postbit_iconmod') . '";');
            }
            else
            {
               if (
in_array($post['usergroupid'],$staffusergroupids))
                {
                   eval(
'$post[\'iconstaff\'] .= "'fetch_template('postbit_iconstaff') . '";');
                }
            }
        } 

Template postbit_iconadmin:
Code:

<div><img src="images/ranks/iconadmin.jpg" alt="$post[usergrouptitle]" border="0"></div>
Template postbit_iconmod:
Code:

<div><img src="images/ranks/iconmod.jpg" alt="$post[usergrouptitle]" border="0"></div>
Template postbit_iconstaff:
Code:

<div><img src="images/ranks/iconstaff.jpg" alt="$post[usergrouptitle]" border="0"></div>
Where the files iconadmin.jpg iconmod.jpg and iconstaff.jpg are thedesired icons for those groups, and are in the images/ranks directory.

Replace '30' with whatever number (or numbers) identify the usergroupsyou want as "staff" - obviously, this is a scalable change: create asmany or as few icon/template pairs as you'd like, and set up the ifstatement in the php file to match.

bkaul 03-16-2005 02:45 AM

The icons I'm using in that modification, for reference:

http://boards.briankaul.com/boards/b.../iconadmin.jpg

http://boards.briankaul.com/boards/b...ks/iconmod.jpg

http://boards.briankaul.com/boards/b.../iconstaff.jpg (Actually this one's currently not assigned to any real groups right now)


All times are GMT. The time now is 01:44 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.01204 seconds
  • Memory Usage 1,749KB
  • 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)bbcode_php_printable
  • (2)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)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