vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Requests/Questions (Unpaid) (https://vborg.vbsupport.ru/forumdisplay.php?f=112)
-   -   Country flag hack? (https://vborg.vbsupport.ru/showthread.php?t=60538)

Roms 09-10-2004 02:57 AM

WAAAHHHOOO! I've been wanting this forever!! works great!!

oldfan 09-30-2004 12:42 PM

works great, thanks :)

lanc3lot 10-01-2004 12:44 PM

Is this hack working for 3.0.3?

oldfan 10-01-2004 05:22 PM

Quote:

Originally Posted by lanc3lot
Is this hack working for 3.0.3?


yep :)

lanc3lot 10-01-2004 09:22 PM

Thanks mate

Neutral Singh 11-04-2004 11:20 AM

I think this thread should be renames as Country Flag Hack and placed in an appropriate section in this forum... :confused: took me a while to locate this hack...

Regards

ChuanSE 11-05-2004 09:50 AM

Quote:

Originally Posted by amanpartaps
I think this thread should be renames as Country Flag Hack and placed in an appropriate section in this forum... :confused: took me a while to locate this hack...

Regards


appropriate section == http://www.vbulletintemplates.com

This is a vB "Hack" board, you are referring to a template altering issue ;)

gilbert 01-13-2005 05:33 AM

This was a real mission for me with VB 3.03 using the instructions included but I finally got it working. Here are some quick instructions:

1. Download the hack
2. Upload the flags, we will use www.yourforum.com/flags/ as an example
3. Note: You do not have to create any new user profiles as there is already a profile for country. The user profile ID for country should be 6 by default.
4. Edit the postbit template,

find

Code:

<if condition="$post['field2']"><div>$vbphrase[location_perm]: $post[field2]</div></if>
below add

Code:

<if condition="$post[field8]"><div>$vbphrase[location_perm]: <img src="http://www.yourforum.com/flags/$post[field6].gif" border="0" alt="[field6]" /><br /></if>
5. This should complete the install. You may have to play around with the
Code:

="$post[field8]">
, just keep changing the field# until you find a spot your are looking for when viewing a thread. For me, 8 worked perfect. Also note that the forum I installed this on did not show the location: in the postbit, if you want to show the location and the country, you will have to create a phrase called "country_12345" with the text "Country: " and then use this code in the postbit style instead:

Code:

<if condition="$post[field8]"><div>$vbphrase[country_12345]: <img src="http://www.yourforum.com/flags/$post[field6].gif" border="0" alt="[field6]" /><br /></if>
Or if you want to do it without creating a new phrase, just put:

Code:

<if condition="$post[field8]"><div>Country: <img src="http://www.yourforum.com/flags/$post[field6].gif" border="0" alt="[field6]" /><br /></if>
Hope this saves some people 2 hours as it would have saved me if I would have known this :)

gilbert 01-13-2005 05:43 AM

1 Attachment(s)
Scratch step number 3. Some people may not have the country list already there. If not, insert all the countries from the flag_list as VB3 allows to add them all. See attachment

T3MEDIA 01-21-2005 07:59 PM

What does this hack do? I saw a site that had country flags scrolling for online users... that is what I would love.
Is there a clear set up on how to do this hack? I really dont want to mess with my site more than it is...

or a screen shot or something! LOL.

T3MEDIA 01-23-2005 07:27 PM

Ok I see now what it does. How can I put this flag in areas such as private messages???

SilverBoy 02-18-2005 12:17 PM

I think the flag hack for vb2.x best than this, coz in vb2 it was modification in database, an altering php files, so u can more control the flags and translate them to any langauge instead of the names of flags files.

coRtALoS 04-08-2005 04:55 AM

1 Attachment(s)
I'd like to share a small modification I've made to this hack which I've found my members really enjoy.

This addon will allow members to display their US State, or Canadian Provincial flags ONLY if they have the United States or Canada selected as their Country.

In addition, if they pick a country that is part of the European Union, it will automatically display the EU flag next to it as well.

I've attached an installer and all necissary files to get it working with the Country hack.

It's a very small addon, and only took me about 5 mins (tops) to get to work once the Country Flag hack was installed.

If you require any technical assistance with this hack, as I am posting this thread on both vBulletin.org, and vBulletinTemplates.com, I will provide technical support for this addon only on my own forums located here:
http://www.battleforums.com/forumdisplay.php?f=288

I also welcome anyone PMing me on my forums as I check my PM box more often than my cellphone voicemail. Please do not PM me here however, as I am not nearly as active on this account.

Enjoy!

~coRtALoS
BattleForums.com, StarCraftForums.com, WarCraftForums.com, DiabloForums.com, and BattleNetwork.com Administrator

~~~Edit~~~

Updated .zip and .txt file to include Quebec Province. :p

~~~2nd Edit~~~

Added European%20Union.gif to .zip

T3MEDIA 04-08-2005 12:06 PM

cool

Limey-YMR 04-18-2005 03:10 AM

Quote:

Originally Posted by coRtALoS
~~~Edit~~~

Updated .zip and .txt file to include Quebec Province. :p

Looks like a great addition - installing now, the EU flag does not appear to be in the installer, though.

This may be a dumb question, but do these extra template conditionals cause much extra server load?

T3MEDIA 04-18-2005 11:18 AM

Not a dumb question at all. It will (to be honest) but so low you will NEVER know. In other words dont worry about it.

coRtALoS 04-18-2005 04:01 PM

1 Attachment(s)
Thanks T3. If you also want to see a working copy of it, just go to any thread on my site http://www.battleforums.com/index.php?. Pretty much every normal poster there is using it now.

I updated the .zip with the EU flag, but I'll attach it in here for ya Limey for convenience purposes.;)

You want to put this in your /images/misc/flags/ folder.

Rickie3 06-12-2005 10:30 AM

thankyou worked a treat

Snake 06-12-2005 12:45 PM

1 Attachment(s)
Thanks guys for the hack instructions. :) I'm pretty sure you'll like my smilies below. Only 2 screenshots are available. Enjoy!

mamboking 06-21-2005 02:24 PM

I am hoping that one of you wonderful coders will develop a hack that would display the country flag .gif in the user's profield instead of the flag text name.

Snake 06-21-2005 03:58 PM

Profield? Do you mean in thread or profile view?

mamboking 06-21-2005 11:31 PM

Quote:

Originally Posted by Snake
Profield? Do you mean in thread or profile view?


Yes. Sorry about that, I was rushing to post while at work.

Snake 06-22-2005 08:34 AM

I thought it shows the country image already in thread view. O.o

Rickie3 06-22-2005 09:09 AM

it does here :-)

mamboking 06-24-2005 03:11 AM

Quote:

Originally Posted by Snake
I thought it shows the country image already in thread view. O.o

I'm not sure wheter or not you are responding to my comment but my request is for view profile not thread view. If not please disregard

Thanx

Snake 06-24-2005 03:12 PM

Quote:

Originally Posted by mamboking
Yes. Sorry about that, I was rushing to post while at work.

Well you were'nt specific in your post. In my opinion, the text is enough instead of an image.

mamboking 06-27-2005 05:28 PM

Ok, let me start over.

You're right I wasn't clear in my post but I thought it bacame clear after you ponited that out and I apologized for the error and stated yes.

I guess I miss read your response. I thought it origianally only asked if I was referring to profile view and I responded yes. But now it looks like you asked if I was referring to thread or profile view. So my answer to that is Profile View.

Your opinion is well recieved but I would like it better if there was a flag image displayed instead of the name. But because I can't code it myself, I am here trying to get some help from somebody. So if this is not something you think is worthy of your time or liking than hopefully someone else can help me with this task because that what I want.

So if anyone could provide the code to make the minor change where the flag image would show in the profile view instead of the flag name, I would appreciate it a lot. If you can help please post the revision here.

Thank you in advance.

Snake 07-05-2005 09:32 AM

Sorry mamo, I ain't a coder so I don't think I can help you out. :( I am already looking for help y'know.

Anyways, I have a few suggestions and ideas for this hack is there anyone who is willing to submit this hack to the database and support it? This hack is lonely and is looking for a perfect author who can really care about it. :D

Snake 07-06-2005 09:56 AM

Well?

sim tech 08-11-2005 08:12 AM

I had a similar mod, where I took the "awareness ribbons" version and changed it to flags that people could buy in Ushop. It's a big hit on my site and I have tons of flags:
http://www.simtechonline.com/atg1.gif

I also added in a bunch of special interest flags (armed sevice flags, special interest groups, etc.).

If anyone wants it (but I don't know if it'll work with 3.5) please let me know.

Examples: (threads on my forum that shows the flags)
http://www.simtechonline.com/forums/...ighlight=flags

http://www.simtechonline.com/forums/...ighlight=flags

andysv1k 08-14-2005 11:04 AM

im having problems installing this mod on ver 3.07

is there any differences in the install to what is posted in this thread?

i think ive done everything right but it just doesnt display any flags :disappointed:

Andy.

Snake 08-14-2005 03:27 PM

andy, I will be creating my own country flag hack pretty soon. I am not sure when it'll be released but the only thing I can say is... soon. ;)

andysv1k 08-14-2005 06:37 PM

Sounds good Snake, im sure whatever im missing is probably something very simple, too simple to notice!

I await your hack eagerly! :)

cheers

Andy.


All times are GMT. The time now is 01:17 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.02247 seconds
  • Memory Usage 1,808KB
  • 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
  • (5)bbcode_code_printable
  • (6)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (33)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