vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.6 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=194)
-   -   Profile Enhancements - Flags - Country and Region (https://vborg.vbsupport.ru/showthread.php?t=155223)

Arrogant-One 10-12-2007 08:09 AM

Quote:

Originally Posted by djrichards (Post 1341802)
I don't get it. His field numbers and order numbers are the same (5 and 6 respectively). What else are you saying that he needs to look at?

I'm asking because I have the exact situation and none of my graphics display.

TIA,

DJ Richards

Help!!!!

I spent about an hour on this stupid Hack and it doesn't seem to be working at all. What have I done wrong?

AO

vitrag24 10-12-2007 03:04 PM

anyone can tell whether it will work on vb 3.6.4?

Arrogant-One 10-17-2007 01:22 AM

Quote:

Originally Posted by vitrag24 (Post 1358311)
anyone can tell whether it will work on vb 3.6.4?

Don't know. I had a professional install it for me on 3.6.7 and it works fine. You select your flag in EDIT PROFILE under USER CP in the navbar.

AO

Digital Jedi 10-19-2007 02:25 AM

Quote:

Originally Posted by Digital Jedi (Post 1322873)
I don't know if anyone will find this useful, but I took the country flag list and ran it through Microsoft Word. They've got a capitalization feature that not too many people know about. And I did a batch rename of the images folder so that all the names would match up. There were a handful of spelling errors in a few country names, so I made sure to correct those and match up the text file with the images. Everything should be formatted and matched properly, but if it isn't let me know.

Like I said, I don't know if you'll find it useful, but since someone mentioned it, I'd thought I'd share what I did for my forum with you. I intend to do the regions folder next, just didn't have the time tonight. I'll post it when it's done.

Took me a while to get around to this. I updated my Regions folder with what I believe to be the correct names and spellings and capitalization. Thought I'd share it with you. Note, your users will have to reselect their flag, and until they do, a broken image will show up. I just went ahead and grouped them altogether.

This should work on any version of vB you have. It's just a template modification. For those having trouble with it, make sure your adding the modifications to the right template. Some of you are using postbit and some of you are using postbit_legacy. If you do the modification to one template, and your forum isn't using that layout, then, naturally, it's not going to show up.

sylar 10-20-2007 08:15 AM

Nice and simple. Very good list of flags as well.

<<Installed>>

vitrag24 10-20-2007 06:53 PM

Cool.
BTW i saw many sites and forums in which after registering countryflag is shown automatic ally.Will this mod work that way or not?
and registered users will need to select flag manually???

peterpigman 10-25-2007 08:34 PM

Ok 3.68 here and working fine, how do you add flags?

Edit: nm figured it out.

Tarola 10-28-2007 03:35 AM

Note:
- for different templates works:
1.Find:

<div class="info">$vbphrase[posts]: $post[posts]</div>

BELOW, ADD:

<!-- / flags start -->
<div>
<if condition="$post[fieldX]"><img src="images/flags/$post[fieldX].gif"></if>
</div>
<!-- / flags end -->

2.Find:
<div>
$vbphrase[posts]: $post[posts]
</div>

BELOW, ADD:

<!-- / flags start -->
<div>
<if condition="$post[fieldX]"><img src="images/flags/$post[fieldX].gif"></if>
</div>
<!-- / flags end -->

iogames 10-30-2007 11:33 PM

Mine stopped working since I've installed another hack... why since this hack is very simple ???

BoneDust 11-20-2007 06:06 AM

I do not see any images? It's probably something stupid as other seem to feel it's an easy install. Images are upload into their appropriate directory, paths are good, postbit legacy code entered etc etc and still no images after 2 hours of trying to see what I am doing wrong.

SNATCH3R 11-21-2007 09:51 AM

thanks and installed............good work

BoneDust 11-21-2007 06:01 PM

Quote:

Originally Posted by BoneDust (Post 1386099)
I do not see any images? It's probably something stupid as other seem to feel it's an easy install. Images are upload into their appropriate directory, paths are good, postbit legacy code entered etc etc and still no images after 2 hours of trying to see what I am doing wrong.


No suggestions? I'm using 3.6.8

BusaNation 11-27-2007 08:35 PM

Hi, I am using your flag program on my global hayabusa site www.BusaNation.com board, it looks great, however, can you take it a step further? Can you take on creating a program that would now TALLEY how many Canadians, americains, UK, etc.... and creat a statistics so that users could see how many flags are represented on my site? asd a user clicks thier country of origin flag, a program would then tally it and show in flag icons so i can place it on my portal home page a visual of the flags and how many users i.e


USA=1000
Canada 55
UK= 2500
spain etc..... just shows the flag icon with a total? from the most to the least in that order, i think it would be awesome and i want to add this to my site? Duane tybal71@hotmail.com www.BusaNation.com:up:

BoneDust 11-27-2007 08:59 PM

Still no images showing up. Anyone have any suggestions?

towermatt 11-27-2007 10:50 PM

Went on great, thank you.

This is cool now that my site has gone kind of international. :D

vitrag24 11-27-2007 11:01 PM

does this shows flags automatically of all users by detecting registration ip or otherway or users have to edit profile for something to display flag?

towermatt 11-28-2007 12:48 AM

It creates a profile field that the user needs to fill in.

But its a drop down so pretty easy.

BoneDust 11-28-2007 03:30 AM

What would cause the images to not show?

Here's what I posted in the postbit - legacy

<!-- / flags start -->
<div>
<if condition="$post[field8]"><img src="images/flags/$post[field8].gif"></if>
<if condition="$post[field9]"><img src="images/region/$post[field9].gif"></if>
</div>

My profile fields are 8 and 9

I uploaded the images to images/flags and images/region

Any thoughts? I've been trying to figure this out for some time and this is the first addon I've had a problem with.

BusaNation 11-28-2007 11:38 AM

Any one know how to get a hold of the CODER? , I cant pM him and he is not taking emails? I want to talk to him about his flag program to do something for my site.

nyunyu 12-07-2007 07:00 PM

Installed this hack but nothing happens? I suppose this hack shows a flag on postbit? Can anyone help me?

Look here.. http://www.animeheist.com/forum/show...61&postcount=1

iogames 12-07-2007 11:21 PM

Quote:

Originally Posted by towermatt (Post 1390744)
It creates a profile field that the user needs to fill in.

But its a drop down so pretty easy.

Quote:

Originally Posted by nyunyu (Post 1396972)
Installed this hack but nothing happens? I suppose this hack shows a flag on postbit? Can anyone help me?

Look here.. http://www.animeheist.com/forum/show...61&postcount=1

Profile Field is the problem ;)

nyunyu 12-08-2007 09:12 AM

iogames, what do you mean by profile field problem? care to explain a little bit more? Thanks

serverguy84 12-23-2007 11:19 AM

This mod shows up in the memberlist. Except it shows up as Canada USA , etc.

Is there any way instead of the writing it shows the flags instead

yeku 12-23-2007 11:28 AM

Reserved

thanks

yeku 12-25-2007 04:53 PM

I have the same question please...:confused::confused:

Quote:

Originally Posted by tiredoff (Post 1358028)
Hi
Admincp > etc.......... it is ok
Options - [copy and paste list of countries in country_flags_list.txt to this option field] But where i can find it?
thank you


serverguy84 12-25-2007 05:07 PM

If you go to Admin->User Profile Fields->Add New User Profile->Single Selection Menu>

In the box where it says
"Options
Enter the options that the user can choose from. Separate each option with a new-line (carriage return)."

That is where you put in all the flags list

yeku 12-25-2007 05:23 PM

Ok, now I understand it

Thanks;);)

sypherzone 01-20-2008 03:46 AM

I tried installing it but it isn't showing? What could be the problem?

Digital Jedi 01-20-2008 07:40 AM

Quote:

Originally Posted by sypherzone (Post 1424880)
I tried installing it but it isn't showing? What could be the problem?

Most common mistake is not putting it into the postbit template that you use for your forum.

postbit (Like on this forum, Avatar and User Info is on top of each post)
postbit_legacy (Avatar and User Info is on the side)


Quote:

Originally Posted by BoneDust (Post 1390811)
What would cause the images to not show?

Here's what I posted in the postbit - legacy

<!-- / flags start -->
<div>
<if condition="$post[field8]"><img src="images/flags/$post[field8].gif"></if>
<if condition="$post[field9]"><img src="images/region/$post[field9].gif"></if>
</div>

My profile fields are 8 and 9

I uploaded the images to images/flags and images/region

Any thoughts? I've been trying to figure this out for some time and this is the first addon I've had a problem with.


It should be showing up, unless your forum isn't using postbit_legacy. Are the images not showing at all, or are they broken images? If they're broken, then you might need to add the flags folders to your skin's images folder, and not the one in your forum root.

ashley53680 01-24-2008 08:26 PM

Beautiful hack that worked perfectly for what I need. I sort of rewrote to meet my needs. I run a local forum so I don't need country flags but more of an area identifier.

I was wondering however, how would you make it a conditional on if the user wants it displayed in their postbit? The field is already something I had in the profile, but now I just added images to go along with the field to display on the postbit. I have some users who don't want it displayed and I am at a loss on how to accomplish that with your hack.

Thanks so much!!!!!

Ash

Digital Jedi 01-24-2008 10:15 PM

The only way I can think of to do that would be to make the field optional. Then it will only show if the user has filled out the field.

ashley53680 01-24-2008 11:54 PM

I thought of that, but I need this field to show in the profiles. It seems redundant to have them fill the information out twice.

I tried to look at the coding on the birthday/age field. There is an option on what of that to display or hide. So I thought I could possibly do it with this as well. I am not a coder, so I am sorry if this seems a bit dense. lol

Digital Jedi 01-26-2008 03:26 PM

What I meant was, you can still change the existing fields you already have to an optional setting, and that way users who don't want it showing can, er, "unfill" the option in their User CP.

Then you can add an if conditional like if condition="$post[fieldX]" around the code, where X is the field ID. That way, if they fill it out, it shows, if they don't it doesn't.

ashley53680 01-26-2008 03:48 PM

Yes that's what I thought you meant, however they *have* to have this filled in. I just want to give them the option to show it in their postbit or not.

R-D 01-27-2008 07:14 AM

Quote:

Originally Posted by Digital Jedi (Post 1363487)
Took me a while to get around to this. I updated my Regions folder with what I believe to be the correct names and spellings and capitalization. Thought I'd share it with you. Note, your users will have to reselect their flag, and until they do, a broken image will show up. I just went ahead and grouped them altogether.

This should work on any version of vB you have. It's just a template modification. For those having trouble with it, make sure your adding the modifications to the right template. Some of you are using postbit and some of you are using postbit_legacy. If you do the modification to one template, and your forum isn't using that layout, then, naturally, it's not going to show up.

Installed! :up:

Digital Jedi 01-27-2008 02:56 PM

Quote:

Originally Posted by ashley53680 (Post 1429396)
Yes that's what I thought you meant, however they *have* to have this filled in. I just want to give them the option to show it in their postbit or not.

Ah, I see. Well, I just tried something on my forum, and it may work for you. Try this out if you like.

Create a new profile field with the question of whether they would like the flags to show in their profile. Make the field a multiple-selection check box, but only create one option: "Yes". Put in the instructions to leave it blank if they don't want it to show. Make sure to make it mandatory and to put it on the same page as the flag options, show during registration, etc.

Then wrap your flag code with <div> tags and put an IF condition around the div. Sort of like so:

Code:

<if condition="$post['fieldX']">
<div>
<if condition="$post[field8]"><img src="images/flags/$post[field8].gif"></if>
<if condition="$post[field9]"><img src="images/region/$post[field9].gif"></if>
</div>

With X being the ID of the new field you just created. What will happen is the DIV wont display unless the user has filled it out: checked "Yes". And since the div wont show, the contents wont either, even if they're a mandatory field.

Hrm, maybe don't make it mandatory. It will HAVE to filled in then. Just make sure to put it on the same page.

R-D 02-01-2008 07:54 AM

I've just been informed by one of my members that there's one incorrect flag in your update, Digital Jedi (and also presumably in the original hack too).

Georgia (the country) should be Attachment 75279. It changed in 2004, here's the Wikipedia article for verification.

Digital Jedi 02-01-2008 02:46 PM

Thanks, R-D. I updated the zip in my post

hunter88 02-06-2008 03:22 PM

Hello,

first: thank you!

Second, i have small questions:

1. its possible to make the flags "hover", do dislpay the flag-name if users take the mouse over the flag? How to make it?

2. its possible to make the flag-name displayed over/under the flags (with Font size 1)?

This is default:

http://bildupload.sro.at/a/images/flags.jpg

and this is what i want (made by GIMP :)):

http://bildupload.sro.at/a/images/flags1.jpg

How to change the code in the templates?

Thanks,

Hunter

(sorry 4 my poor english)

R-D 02-08-2008 11:35 PM

Quote:

Originally Posted by Digital Jedi (Post 1433982)
Thanks, R-D. I updated the zip in my post

Thank you for the updates of this mod, it is much appreciated. :)


All times are GMT. The time now is 01:42 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.01523 seconds
  • Memory Usage 1,835KB
  • 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
  • (1)bbcode_code_printable
  • (12)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)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