vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 4.x Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=245)
-   -   Add-On Releases - Country Flags - Postbit & Postbit_Legacy. vB 4.0.x (Inc GO (https://vborg.vbsupport.ru/showthread.php?t=229511)

Welshy2008 04-27-2011 08:52 AM

Lol - thanks for updating your post.

K!nG 04-29-2011 07:24 PM

Great Mod.... Working on 4.1.3 :) default n custom skinz

Furcal15 05-11-2011 08:40 PM

I tried using the last template edit that is for 4.1.1 on my 4.1.3 and couldn't get it to work. I used the code for 4.0.6-4.0.7 which is this:

Code:

<!-- Wy Country Flags Start -->
<vb:if condition="$post['fieldX']"> <dt>Country</dt> <img src="http://www.YOURFORUM ADDRESS.com/forum/images/buttons/flags/{vb:raw post.fieldX}.GIF" alt="This is {vb:raw post.username}'s Country Flag" border="" /></vb:if></p>
<!-- Wy Flags End -->

And it worked fine. Although, I did not use this for country flags. Instead I used it for my baseball forum and choosing your favorite team, it works wonders. If you want to use it for something else like I did here is how I did it (it is modified).


Code:

<!-- Wy Country Flags Start -->
<vb:if condition="$post['field15']"><img src="http://www.baseballnation.net/images/teams/{vb:raw post.field15}.png" alt="This is {vb:raw post.username}'s favorite team." border="" /></vb:if></p>
<!-- Wy Flags End -->

As you can see, I changed the original image file extension from .GIF to .png....I also took out
Code:

<dt>Country</dt>
so no text displays, just my logo.

If you want to use it for something other than country flags. Your image name must match the option name.

For instance in options I had the whole list of MLB teams instead of a list of countries. It looks like this:

Code:

Arizona Diamondbacks
Atlanta Braves
Baltimore Orioles
Boston Red Sox
Chicago White Sox
Chicago Cubs
Cincinnati Reds
Cleveland Indians
Colorado Rockies
Detroit Tigers
Florida Marlins
Houston Astros
Kansas City Royals
Los Angeles Angels
Los Angeles Dodgers
Milwaukee Brewers
Minnesota Twins
New York Mets
New York Yankees
Oakland Athletics
Philadelphia Phillies
Pittsburgh Pirates
San Diego Padres
San Francisco Giants
Seattle Mariners
St. Louis Cardinals
Tampa Bay Rays
Texas Rangers
Toronto Blue Jays
Washington Nationals

All my images in the images/teams directory have to match the option names exactly. So for the Arizona Diamondbacks...In my images/teams folder it is saved exactly how it is in the options list for the field. The image is Arizona Diamondbacks.png --- It must be typed exactly how it is in the options field.

TEMPESTADE 05-12-2011 01:37 PM

good everything is well explained but what is the code for version 4.1.3 of someone kind soul can tell I'm confused! grateful

billstelling 05-12-2011 02:27 PM

1 Attachment(s)
Find this in the postbit_legacy and add it just below it.
Code:

<img src="{vb:raw post.avatarurl}" alt="{vb:rawphrase xs_avatar, {vb:raw post.username}}" title="{vb:rawphrase xs_avatar, {vb:raw post.username}}" />
                        </a>
                        </vb:if>
                        <vb:if condition="$post['userid']">
                                <hr />
                                <dl class="userinfo_extra">

and i changed the code slightly to get rid of "Country:"
Code:

<!-- Wy Country Flags Start -->
<vb:if condition="$post['field5']"><img src="{vb:stylevar imgdir_button}/flags/{vb:raw post.field5}.GIF" alt="Users Country Flag" border="" /></vb:if>
<!-- Wy Flags End -->

I got it to work after a little trial and error.. It needs to be placed below the avatar code when you have modded the post bits all to hell.. I have several adds to it and once i found were it needed to go it works great! Oh, I am using vB 4.1.3

Attachment 129010

doctorsexy 05-24-2011 12:42 PM

installed on 4.1.3 with a bit of head scratchin...thanks

dearone 05-25-2011 03:17 AM

guys still i can not isntall it in 4.1.3

joeychgo 05-25-2011 07:39 AM

1 Attachment(s)
I've installed it but I keep getting this alignment issue where it's at the side of the avatar.

billstelling 05-25-2011 11:14 PM

did you put it below <dl class="userinfo_extra">
I had to experiment a bit to find were to put it.. post were you put it in the code and we will see if we can help.

EasyEazy 05-29-2011 01:21 PM

Installed and looking great. Great mod and thanks for the effort put in.


All times are GMT. The time now is 12:48 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.01765 seconds
  • Memory Usage 1,742KB
  • 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
  • (6)bbcode_code_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (2)pagenav_pagelinkrel
  • (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