Go Back   vb.org Archive > vBulletin Modifications > vBulletin 4.x Modifications > vBulletin 4.x Template Modifications
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Postbit Legacy - Usergroup Backgrounds vb4 Details »»
Postbit Legacy - Usergroup Backgrounds vb4
Version: 4.0.1, by Fastbird Fastbird is offline
Developer Last Online: Jan 2012 Show Printable Version Email this Page

Category: Show Thread Enhancements - Version: 4.0.1 Rating:
Released: 12-03-2009 Last Update: Never Installs: 47
Template Edits
Re-useable Code Code Changes Translations  
No support by the author.

Updated for vBulletin 4.0.1!!!!

Hey Everyone! I went ahead and updated my vb3.x.x mod to work with the new coding in vBulletin 4. There are a few more modifications to make than the last time, but overall, I think you will find this very easy.

To start, let's look at a screenshot of what this mod will do for you, it's the image behind the username and the posbit information. This will not do anything else but assign a special background to the specified usergroup and assign the regular styling to all other usergroups:

DEMO: http://ltxtech.com/forums/showthread...or-New-Upgrade

Now that you have decided to continue with the modification, let's begin!

Navigate to:

Style Manager --> Click on the << >> Next to the template you are editing -->CSS Templates

postbit.css


FIND:
Code:
.postbitlegacy .userinfo {
	float:{vb:stylevar left};
	position: relative;
	width: {vb:math {vb:stylevar postbitlegacy_userinfo_width}-{vb:math {vb:stylevar padding}*2}}; 
	padding: 2px {vb:stylevar padding} {vb:math {vb:stylevar padding}/2};
	font-size: {vb:stylevar small_fontSize};
	display:block;
        background: {vb:stylevar postbit_userinfo_background};
	_background-image: none;
	_margin-top: -{vb:math {vb:math 16px*{vb:stylevar line_height}} + {vb:stylevar padding}-{vb:stylevar postbit_border.borderWidth}};
	clear:both;
}
ADD UNDER:
Code:
/*Custom Postbit Background - Image*/
.postbitlegacy .userinfo2 {
	float:{vb:stylevar left};
	position: relative;
	width:{vb:math {vb:stylevar postbitlegacy_userinfo_width}-{vb:math {vb:stylevar 
padding}*2}}; 
	padding: 2px {vb:stylevar padding} {vb:math {vb:stylevar padding}/2};
	font-size: {vb:stylevar small_fontSize};
	display:block;
       background: #xxxxxx /*url(url to image here) no-repeat*/;
        _margin-top: -{vb:math {vb:math 16px*{vb:stylevar line_height}} + {vb:stylevar padding}-{vb:stylevar postbit_border.borderWidth}};
	clear:both;
}
---> Note: The Red xxxxxx is a color number. You need to specify a background color in case you aren't using an image. Remove the /* and */ around the url code to use an image. Otherwise it will just change the color of the box. I suggest fading the image to the color of the background you choose, as shown in the picture example.

FIND:
Code:
.postbitlegacy .userinfo .postuseravatar img, .eventbit userinfo .eventuseravatar img {
	border: {vb:stylevar postbitlegacy_avatar_border};
 	outline: {vb:stylevar postbitlegacy_avatar_outline};
 	max-width: {vb:math {vb:stylevar postbitlegacy_userinfo_width} - {vb:math {vb:stylevar padding}*2}- {vb:math {vb:stylevar postbitlegacy_avatar_outline.borderWidth}*2} - {vb:math {vb:stylevar postbitlegacy_avatar_border.borderWidth}*2}};
}
ADD UNDER:
Code:
/*Custom Postbit Background - Avatar Border*/
.postbitlegacy .userinfo2 .postuseravatar img, .eventbit userinfo .eventuseravatar img {
	border: {vb:stylevar postbitlegacy_avatar_border};
 	outline: {vb:stylevar postbitlegacy_avatar_outline};
 	max-width: {vb:math {vb:stylevar postbitlegacy_userinfo_width} - {vb:math {vb:stylevar padding}*2}- {vb:math {vb:stylevar postbitlegacy_avatar_outline.borderWidth}*2} - {vb:math {vb:stylevar postbitlegacy_avatar_border.borderWidth}*2}};
}
FIND:
Code:
.postbitlegacy .userinfo a.username, .eventbit .userinfo a.username {
	clear:right;
	font-size:21px;
	font-weight:none;
	width: auto;
	max-width:{vb:math {vb:stylevar postbitlegacy_userinfo_width} - {vb:math {vb:stylevar padding}*2} - 20px};
	word-wrap:break-word;
}
ADD UNDER:
Code:
/*Custom Postbit Background - Username Style*/
.postbitlegacy .userinfo2 a.username, .eventbit .userinfo a.username {
	clear:right;
	font-size:21px;
	font-weight:none;
	width: auto;
	max-width:{vb:math {vb:stylevar postbitlegacy_userinfo_width} - {vb:math {vb:stylevar padding}*2} - 20px};
	word-wrap:break-word;
}
FIND:
Code:
.postbitlegacy .userinfo .postuseravatar, .eventbit .userinfo .eventuseravatar {
	display:block;
	margin:{vb:math {vb:stylevar padding}/3} auto 0;
	text-align:center;
	width: auto;
}
ADD UNDER:
Code:
/*Custom Postbit Background - Avatar Position*/
.postbitlegacy .userinfo2 .postuseravatar, .eventbit .userinfo .eventuseravatar {
	display:block;
	margin:{vb:math {vb:stylevar padding}/3} auto 0;
	text-align:center;
	width: auto;
}
FIND:
Code:
.postbitlegacy dl.userinfo_extra dt, .postbitlegacy dl.user_rep dt {
	float: {vb:stylevar left};
	text-align: {vb:stylevar left};
	/*color: {vb:stylevar shade_color};*/
	margin-{vb:stylevar right}: {vb:stylevar padding};
	margin-{vb:stylevar left}: 0;
	min-width:60px;
	width:auto !important;
	width:60px;
}
ADD UNDER:
/*Custom Postbit Background - Userinfo Alignment*/
Code:
.postbitlegacy dl.userinfo_extra2 dt, .postbitlegacy dl.user_rep dt {
	float: {vb:stylevar left};
	text-align: {vb:stylevar left};
	/*color: {vb:stylevar shade_color};*/
	margin-{vb:stylevar right}: {vb:stylevar padding};
	margin-{vb:stylevar left}: 0;
	min-width:60px;
	width:auto !important;
	width:60px;
}
That does it for the CSS file. Now we need to do one last thing, and that's edit the posbit_legacy template.

Navigate to:

Style Manager --> Click on the << >> Next to the template you are editing -->Postbit Templates

postbit_legacy:

FIND:
Code:
<div class="userinfo">
REPLACE:
Code:
<vb:if condition="is_member_of($post, #)"><div class="userinfo2">
<vb:else />
<div class="userinfo">
</vb:if>
FIND:
Code:
<dl class="userinfo_extra">
REPLACE:
Code:
<vb:if condition="is_member_of($post, #)"><dl class="userinfo_extra2">
<vb:else />
<dl class="userinfo_extra">
</vb:if>
The RED # is the ID of the usergroup that you want to have a unique background. In my example picture, the administrators have the custom image, so the # sign is replaced in the code with a 6, because the ID for the administrator usergroup is 6. To find the ID, go to usergroup options in the AdminCP and look at the chart. The group ID should be on the same line as the usergroup name.

All right! You should now have a styled postbit legacy background image for a specific usergroup!

I can't really provide support, I'm extremely busy with work and life, but if I pop in from time to time I'll try to help. Also, please, please, please create your own background image. I do not want my image being used. If you would like to setup the modification and use my image to get it up and running, that's fine. But I am asking that you create your own after it's installed properly.

Good luck guys!

Screenshots

File Type: jpg admin_back.jpg (112.3 KB, 0 views)

Supporters / CoAuthors

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #62  
Old 02-18-2012, 01:57 PM
HHelp1's Avatar
HHelp1 HHelp1 is offline
 
Join Date: May 2011
Location: Florida
Posts: 275
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by d19rnyxx View Post
Brilliant mod but can't get it to work because of the custom theme.
yES and i think it no longer work for 4.1.8 or greater
Reply With Quote
  #63  
Old 02-18-2012, 03:16 PM
RobbieZ RobbieZ is offline
 
Join Date: Jul 2008
Posts: 1,117
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by HHelp1 View Post
yES and i think it no longer work for 4.1.8 or greater
Still working on 4.1.11 !
Reply With Quote
  #64  
Old 02-18-2012, 10:08 PM
HHelp1's Avatar
HHelp1 HHelp1 is offline
 
Join Date: May 2011
Location: Florida
Posts: 275
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Only for default ? Or any style ?
Reply With Quote
  #65  
Old 03-13-2012, 11:16 PM
wishtheend wishtheend is offline
 
Join Date: Dec 2009
Posts: 29
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Installed fine, but does anyone know if the userinfo2 can be extended so it runs the length of the actual post? Mine also cuts off after the user info, but I'd like it to run the length of the post as indicated by this arrow

Example Pic
Reply With Quote
  #66  
Old 06-21-2012, 03:05 PM
Nocturnal222 Nocturnal222 is offline
 
Join Date: Dec 2006
Posts: 121
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

thanks working at vb4 latest version
Reply With Quote
  #67  
Old 07-05-2012, 08:25 AM
Pure Dope Pure Dope is offline
 
Join Date: Dec 2006
Posts: 165
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

this is wonderful! but 2 many template mods.
Reply With Quote
  #68  
Old 07-05-2012, 08:26 AM
Pure Dope Pure Dope is offline
 
Join Date: Dec 2006
Posts: 165
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

if you can get the template mods down to 0 and make the background for the entire post for the usergroup, that would be awesome!
Reply With Quote
  #69  
Old 10-27-2012, 11:49 AM
Subieforums Subieforums is offline
 
Join Date: Sep 2012
Posts: 44
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

This mod looks pretty badarse...

Is there a certain size the background images have to be for this? Just asking before I start adding this code, as I want to make custom graphics for each of the usergroups. Thanks!
Reply With Quote
  #70  
Old 01-10-2013, 11:33 AM
Luis's Avatar
Luis Luis is offline
 
Join Date: May 2011
Posts: 77
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Fastbird View Post
One usergroup is like this:
Code:
<vb:if condition="is_member_of($post, #)"><dl class="userinfo_extra2">
<vb:else />
<dl class="userinfo_extra">
</vb:if>
Two usergroups is like this:
Code:
<vb:if condition="is_member_of($post, #)"><dl class="userinfo_extra2">
<vb:else />
<vb:if condition="is_member_of($post, #)"><dl class="userinfo_extra3">
<vb:else />
<dl class="userinfo_extra">
</vb:if>
</vb:if>
You keep adding the statement over and over and then add a vb:if at the end for each additional phrase you add. Then, you must duplicate the css each time for each usergroup. So, in the example for installation, I use userinfo2 for the duplicate css codes. Each additional usergroup will have an incremental increase, so the css for the 2nd usergroup would be userinfo3, the 3rd user group would use userinfo4, and so on. Just keep duplicating each of the steps above for each usergroup.
done xD!
Reply With Quote
  #71  
Old 01-10-2013, 05:04 PM
FTG LIQUID CL FTG LIQUID CL is offline
 
Join Date: Jan 2012
Posts: 158
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Does not seem to work with 4.1.12
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:06 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04588 seconds
  • Memory Usage 2,352KB
  • Queries Executed 27 (?)
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
  • (16)bbcode_code
  • (3)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (4)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (1)postbit_attachment
  • (11)postbit_onlinestatus
  • (11)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_attachment
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete