vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.8 Template Modifications (https://vborg.vbsupport.ru/forumdisplay.php?f=236)
-   -   Miscellaneous Hacks - Postbit Legacy - Usergroup Backgrounds (https://vborg.vbsupport.ru/showthread.php?t=203850)

Fastbird 04-15-2009 09:43 PM

Quote:

Originally Posted by therogueforums (Post 1791908)
TY :) Sadly, it didn't work for me. The first solution is the one I tried last night. The last one, above, yeilds the same results ("you're missing a </if> tag! oh n0es!") and the avatar, etc gets shoved out to the right.

That really shouldn't be happening. Are you sure you have two CSS conditions setup for the script? Try copying the code I gave you verbatim, missing tag and all and see what it does, just change the css triggers over to whatever you use.

Can you post up your postbit so I can look it over?

down.low 04-15-2009 11:45 PM

Quote:

Originally Posted by therogueforums (Post 1791616)
Very promising mod. Thank you, firstly. Now...

When I add more than 1 usergroup to this... the first usergroup I added (administrators) is borked a bit. The image shows up fine, but the avatar, username, etc is force "out" to the right, where the actual post should be.

Any ideas on what I'm doing wrong? Possibly, if you have the time... maybe make a "template" for those who wish to use this for multiple usergroups? Also... and I suspect you're pretty busy, and can understand if you don't want to throw this in... but any way you can code in some curved boxes, where the posts, join date, etc go? I tried to use your mod with another mod that adds the boxes, but the image just ended up in there, in addition to the rest of the postbit, which didn't look so hawt. Lastly... again, if you have time, maybe throw in a signature cell, below it all.

At any rate, thank you for your time, and I look forward to a response.

|
|

I had this problem when adding more then one group. What you are doing wrong is adding the following code to many times- there should only be 1 instance of this code:
Code:

<td class="alt2" width="175" style="border: $stylevar[cellspacing]px solid $stylevar[tborder_bgcolor]; border-top: 0px; border-bottom: 0px">
|
|

Here is a code for 1 background/group(after changing the red):
Quote:

Code:


In your postbit_legacy.

        <if condition="is_member_of($post, groupid)">
        <td class="css name1" width="175" style="border: $stylevar[cellspacing]px solid $stylevar [tborder_bgcolor]; border-top: 0px; border-bottom: 0px id="td_post_$post[postid]">
        <else />
        <td class="alt2" width="175" style="border: $stylevar[cellspacing]px solid $stylevar[tborder_bgcolor]; border-top: 0px; border-bottom: 0px"></if>

Code:


And this code (after changing the red) would have to be in your additional css.


.css name1 {
background: #000000 url(image path);
background-repeat: repeat;
border-left: solid 0px #border color;
border-right: solid 1px #border color;
}


|
|
Two backgrounds/groups would look like this:
Quote:

Code:

In your postbit_legacy.


        <if condition="is_member_of($post, groupid2)">
        <td class="css name2" width="175" style="border: $stylevar[cellspacing]px solid $stylevar [tborder_bgcolor]; border-top: 0px; border-bottom: 0px id="td_post_$post[postid]">
        <else />
        <if condition="is_member_of($post, groupid1)">
        <td class="css name1" width="175" style="border: $stylevar[cellspacing]px solid $stylevar [tborder_bgcolor]; border-top: 0px; border-bottom: 0px id="td_post_$post[postid]">
        <else />
        <td class="alt2" width="175" style="border: $stylevar[cellspacing]px solid $stylevar[tborder_bgcolor]; border-top: 0px; border-bottom: 0px"></if></if>



Notice: I had to add the additional </if> to the very end!!


|
|
Code:

And this code (after changing the red) would have to be in your additional css:
.css name1 {
 background: #000000 url(image path);
 background-repeat: repeat;
 border-left: solid 0px #border color;
 border-right: solid 1px #border color;
 }
.css name2 {
  background: #000000 url(image path);
  background-repeat: repeat;
  border-left: solid 0px #border color;
  border-right: solid 1px #border color;
  }


|
|
Three backgrounds/groups would look like this:
Quote:

Code:

In your postbit_legacy.


       
        <if condition="is_member_of($post, groupid3)">
        <td class="css name3" width="175" style="border: $stylevar[cellspacing]px solid $stylevar [tborder_bgcolor]; border-top: 0px; border-bottom: 0px id="td_post_$post[postid]">
        <else />
        <if condition="is_member_of($post, groupid2)">
        <td class="css name2" width="175" style="border: $stylevar[cellspacing]px solid $stylevar [tborder_bgcolor]; border-top: 0px; border-bottom: 0px id="td_post_$post[postid]">
        <else />
        <if condition="is_member_of($post, groupid1)">
        <td class="css name1" width="175" style="border: $stylevar[cellspacing]px solid $stylevar [tborder_bgcolor]; border-top: 0px; border-bottom: 0px id="td_post_$post[postid]">
        <else />
        <td class="alt2" width="175" style="border: $stylevar[cellspacing]px solid $stylevar[tborder_bgcolor]; border-top: 0px; border-bottom: 0px"></if></if></if>



Notice: I had to add the additional </if> to the very end (AGAIN)!!

|
|

Code:

And this code (after changing the red) would have to be in your additional css:


.css name1 {
 background: #000000 url(image path);
 background-repeat: repeat;
 border-left: solid 0px #border color;
 border-right: solid 1px #border color;
 }
.css name2 {
  background: #000000 url(image path);
  background-repeat: repeat;
  border-left: solid 0px #border color;
  border-right: solid 1px #border color;
  }
.css name3 {
  background: #000000 url(image path);
  background-repeat: repeat;
  border-left: solid 0px #border color;
  border-right: solid 1px #border color;
  }



Fastbird 04-15-2009 11:46 PM

Yeah, thanks for clearing that up. I tried to explain that, that you need independent CSS for each statement, but the if tags I didn't know about. I'll update the initial install info. Thanks!

down.low 04-15-2009 11:52 PM

Quote:

Originally Posted by Fastbird (Post 1790706)
Ok, here's how to center everything:

Find:

<div id="postmenu_$post[postid]">

Replace:

<div id="postmenu_$post[postid]" align="center">

Find:
<div class="smallfont">

Replace:
<div class="smallfont" align="center">

Thanks for helping buddy, That did center my name and the title under my name- could you point me in the direction to center the rest of the stuff under- like my avatar and such?

down.low 04-15-2009 11:55 PM

Quote:

Originally Posted by Fastbird (Post 1792069)
Yeah, thanks for clearing that up. I tried to explain that, that you need independent CSS for each statement, but the if tags I didn't know about. I'll update the initial install info. Thanks!

Well the post post someone else posted sort of left that out and their code had the extra bit in it and didn't mention to only have it once. Took my a while to figure it out myself but I enjoy learning.

down.low 04-15-2009 11:57 PM

Quote:

Originally Posted by down.low (Post 1792073)
Thanks for helping buddy, That did center my name and the title under my name- could you point me in the direction to center the rest of the stuff under- like my avatar and such?

cancel the avatar- I got it centered.

down.low 04-16-2009 12:23 AM

Quote:

Originally Posted by down.low (Post 1792076)
cancel the avatar- I got it centered.

allright I got everything centered, thanks for helping out.

Fastbird 04-16-2009 12:12 PM

:) Thanks for helping out!

therogueforums 04-19-2009 09:13 PM

Quote:

Originally Posted by down.low (Post 1792068)
...


Thank you, so much! Worked like a charm!

mikey1991 04-20-2009 02:59 AM

great mod, saw it a awhile ago, tagged it.


All times are GMT. The time now is 01:04 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.01413 seconds
  • Memory Usage 1,767KB
  • 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
  • (7)bbcode_code_printable
  • (10)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