Go Back   vb.org Archive > Community Discussions > Modification Requests/Questions (Unpaid)
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 06-27-2008, 03:43 PM
Renny Renny is offline
 
Join Date: Mar 2008
Posts: 23
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default User specific text colour

Hello,

Is there a way you can make it so a user group when posting is automatically given a text colour to the colour i chose?
Ive been looking for sometime on how to do this but ive had no luck and cant find any mods/hacks on how to do this

However i know it can be done becuase i use to use a layout that did just that, but i dont want to use the layout.

Thanks
Reply With Quote
  #2  
Old 06-29-2008, 03:34 AM
wwolf27 wwolf27 is offline
 
Join Date: Feb 2008
Posts: 80
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Renny View Post
Hello,

Is there a way i can make it so a user group when posting is automatically given a text colour to the colour i chose?
Ive been looking for sometime on how to do this but ive had no luck and cant find any mods/hacks on how to do this

However i know it can be done becuase i use to use a layout that did just that, but i dont want to use the layout.

Thanks
I to am interested
Reply With Quote
  #3  
Old 07-03-2008, 05:59 PM
Karri's Avatar
Karri Karri is offline
 
Join Date: Feb 2002
Posts: 98
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

This is how I managed to make it work. I do it so that certain users get a certain color but it translates easily to the whole group getting the color you pick.

Go to your skins css and define something like

.VIP_Group { color:#000000 }

Then go to your postbit template and find

Code:
<!-- message -->
<div id="post_message_$post[postid]">$post[message]</div>
<!-- / message -->

and replace with

Code:
		<!-- message -->              
<if condition="(in_array($post['usergroupid'],  array('group number goes here')))">
    <span class="VIP_Group"><div id="post_message_$post[postid]">$post[message]</div></span>
<else />
 <div id="post_message_$post[postid]">$post[message]</div>
</if>

		<!-- / message -->

That should do what you are looking for.
Reply With Quote
  #4  
Old 07-03-2008, 06:35 PM
Renny Renny is offline
 
Join Date: Mar 2008
Posts: 23
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Ive tried to do what you have suggested but it hasnt worked.

This bit here;
PHP Code:
array('group number goes here')))"> 
Just making sure, this is what ive put. Is it correct?
PHP Code:
array('6')))"> 
And the CSS code goes in the "Additional CSS Definitions" correct?

Thanks,
Renny
Reply With Quote
  #5  
Old 07-03-2008, 07:00 PM
Opserty Opserty is offline
 
Join Date: Apr 2007
Posts: 4,103
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

AdminCP > Usergroups > Usergroup Manager > Edit Usergroup > Username HTML markup
Reply With Quote
  #6  
Old 07-03-2008, 07:12 PM
Renny Renny is offline
 
Join Date: Mar 2008
Posts: 23
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Opserty View Post
AdminCP > Usergroups > Usergroup Manager > Edit Usergroup > Username HTML markup
Im sorry but what you have just posted isnt relivent. Its the Text of the posts the usergroup posts, not the username. Maybe you should read more carefully ?
Reply With Quote
  #7  
Old 07-03-2008, 07:34 PM
Karri's Avatar
Karri Karri is offline
 
Join Date: Feb 2002
Posts: 98
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Renny View Post
Ive tried to do what you have suggested but it hasnt worked.

This bit here;
PHP Code:
array('group number goes here')))"> 
Just making sure, this is what ive put. Is it correct?
PHP Code:
array('6')))"> 
And the CSS code goes in the "Additional CSS Definitions" correct?

Thanks,
Renny
That is the code I use, of course I have more than one group getting colored but I just tried changing my code to match what I posted and the colors still worked. Yes I have the CSS in the additional CSS section. Silly question but the code I posted was for black text, you did change it to a color that would be different than your standard color?

EDITED TO ADD: also you put it in the postbit template you are using? I didn't specify but if you are using postbit_legacy then it needs to go in there.
Reply With Quote
  #8  
Old 07-03-2008, 07:45 PM
Renny Renny is offline
 
Join Date: Mar 2008
Posts: 23
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Karri View Post
That is the code I use, of course I have more than one group getting colored but I just tried changing my code to match what I posted and the colors still worked. Yes I have the CSS in the additional CSS section. Silly question but the code I posted was for black text, you did change it to a color that would be different than your standard color?
Yes i changed the colour to #04c0ff. In the edit template which postbit are you talking about, just to make sure ive got the righ tone it is the one called "postit" with out any "postbit_XXXXXX"?
Reply With Quote
  #9  
Old 07-03-2008, 07:57 PM
Karri's Avatar
Karri Karri is offline
 
Join Date: Feb 2002
Posts: 98
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Depends on which one you are using on your site, if you are using the legacy layout then you need to use postbit_legacy if you are using the layout like in the posts here you need to use postbit. Check vbulletin options, Style & Language Settings, Use Legacy (Vertical) Postbit Template if that is set to yes then edit the postbit_legacy template. If that is set to no then do the postbit template.
Reply With Quote
  #10  
Old 07-03-2008, 08:14 PM
Renny Renny is offline
 
Join Date: Mar 2008
Posts: 23
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Karri View Post
Depends on which one you are using on your site, if you are using the legacy layout then you need to use postbit_legacy if you are using the layout like in the posts here you need to use postbit. Check vbulletin options, Style & Language Settings, Use Legacy (Vertical) Postbit Template if that is set to yes then edit the postbit_legacy template. If that is set to no then do the postbit template.
Im using postbit_legacy, ive found and edited the code like youve told me to and yet still no luck... ill have a bit of a mess around more tomorrow and post if any developments, thanks for your help and time =]
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 02:45 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.04274 seconds
  • Memory Usage 2,265KB
  • Queries Executed 11 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (2)bbcode_code
  • (4)bbcode_php
  • (5)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (10)postbit
  • (10)postbit_onlinestatus
  • (10)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.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
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete