View Full Version : State Flags
Lamby1973
12-21-2005, 10:00 PM
For this, its exactly the same as the Country Flag hack, however this shows where abouts you live.
IE....
Flag > England
State Flag > Yorkshire/Northumberland....etc etc
You dont need to have the Country Flag addon installed on your board to use this, this is totally seperate.
I have tested this an it worked on my 3.5.2 board. It should work on any version of 3.5 :)
Any bugs or quieres then just let me know, ill try my best to help you out :)
Jon
mholtum
12-22-2005, 07:31 PM
Installed.. Easy money. thank you!
Lamby1973
12-22-2005, 08:01 PM
Your Welcome!
bashy
12-22-2005, 08:51 PM
hi
I cannot find
<div>
$vbphrase[posts]: $post[posts]
</div>
in either postbit nor postbit legacy, what do i do with this code now lol
I have searched all the way through, I have like 70 other modifications done to my board so this code may have been modded already!!
Bashy
bashy
12-22-2005, 09:06 PM
I have just dumped the code anywhere in legacy and it sort of works...
the flags arnt showing though...
Theres not even any place holders for the pics to show that they are in the wrong place or out like that :(
Any thoughts?
Bashy
Lamby1973
12-22-2005, 09:43 PM
Your pictures should have been uploaded to your images file as stated in the install file....least i think i put it in there.
And i would have said if you cant find that then look for this:
<if condition="$show['reputation']"><div><if condition="$show['reppower']">$vbphrase[reppower]: $post[reppower]</if>$post[reputationdisplay]</div></if>
And place it above it.
bashy
12-22-2005, 09:49 PM
Hi
No ya didnt say that in the instructions :)
will try it though thanks
State Flag Mod for vb 3.5
This hack shows user's state flag (Where abouts in there country they come from) in postbit, below the user name or country flag (If installed).
As part of the Country Flag mod, State Flag mod created by Jonathan Thomas
1. Go to AdminCP => Profile Fields => Add new Profile field => Single Select Menu >
Title > Home County/State
Description > Tell people where abouts your from
Options:
[copy and paste list of countries in state_list.txt to this option field]
Set Default: Yes, none
Editable By User: Yes
Display Page: Edit Profile
Write down your field# . i.e field6
2. Open postbit(_legacy) template,
FIND:
<div>
$vbphrase[posts]: $post[posts]
</div>
BELOW, ADD:
<if condition="$post[fieldX] != ''"><div>
State/County: <img src="images/state/$post[fieldX].gif" title="$post[fieldX]" align="center">
</div></if>
<!-- Change X to the field id. -->
3. Upload /state to images/state to your forum dir.
<!--- That's it! --->
Lamby1973
12-22-2005, 09:50 PM
Yes i did ;)
3. Upload /state to images/state to your forum dir.
Always read to the end ;)
bashy
12-22-2005, 09:55 PM
I was reffering to the
<if condition="$show['reputation']"><div><if condition="$show['reppower']">$vbphrase[reppower]: $post[reppower]</if>$post[reputationdisplay]</div></if>
That was not in the instructions...
As for the images, this is where they are...
/forums/images/state/
Regards
Bashy
Lamby1973
12-22-2005, 09:59 PM
ah right yeah i know, because i didnt think that would be gone from peoples postsbits! lol
So i was just suggesting another place for you to put them :)
bashy
12-22-2005, 10:00 PM
Ah...im with ya...
Still not working though lol, well the images anyway lol
Bashy
Lamby1973
12-22-2005, 10:04 PM
link me to your forum, and will have a look from there :)
Right double check for me that you've created the new profile fields in your admin CP....and also changed the X's in the code to the number of that profile field....
bashy
12-22-2005, 10:06 PM
Hi
sorry that should have been 1 of the 1st things i should have put lol
www.bashys-place.com
Bashy
Lamby1973
12-22-2005, 10:16 PM
There so much stuff on there it would suprise me if it clashed tbh....
Cant think of anything else other than what ive suggested
bashy
12-22-2005, 10:19 PM
Ok Lamby, no worries....
It had to happen sooner or later, i have about 71 mods installed including yours :)...
Oh well at least the area is showing..
thanks for looking and trying anyway...
Regards
Bashy
Rickie3
12-22-2005, 11:55 PM
works a treat thankyou *installed*,the only thing i have to do is change the state pic sizes to correspond to my country flags size of 30x15 the state flags are 32x20,is there a quick way of doing this??
Lamby1973
12-23-2005, 09:02 AM
Erm, im not entirely sure! I think you would have to put them in an editor like fireworks and just change the canvas size :)
bashy
12-23-2005, 09:58 AM
Hi lamby
I had another go now that im fully awake...
I finally sorted it...
Sometimes things work using the postbit_legacy and other times just using the postbit...
It was postbit this time, and i also moved it further up to just under the users loacation, looks better there :)
Regards
Bashy
*clicks install
Rickie3
12-23-2005, 10:17 AM
i have a request::::you don't appear to have included a flag for the "state of confusion', which is what i generally seem to be in these days.
Lamby1973
12-23-2005, 12:55 PM
lmao!!!
Will have a crack at that flag for you! ;)
Lamby1973
12-23-2005, 01:02 PM
There you go, You state of confusion. lol
Simply right click on the image and save as, and add it to your States Folder.
And in your list in the AdminCP add this: State of Confusion
Note: Just a little note that it may have to go in Alphabetical order, im not sure.
:) Hope that surfices for you :) :D
Rickie3
12-23-2005, 09:50 PM
hahahahahahahaa PMSL thanx for that,and i did use it lol
Lamby1973
12-24-2005, 03:16 PM
;) glad you liked it lol!
bashy
12-24-2005, 03:55 PM
Hi lamby...
Is this meant to add 1 or 2 flags, im sure ive see other forums with 2?
Or are they using to mods?
Bashy
Lamby1973
12-24-2005, 04:07 PM
Its supposed to add one flag....the other is the CountryFlag add on!
bashy
12-24-2005, 06:51 PM
Thats what i thought...
Thanks lamby :)
Lamby1973
12-24-2005, 06:53 PM
No problem :)
Ole_Chilli
12-24-2005, 10:56 PM
Okay I may be an idiot ,,
but I have no "Options" to place the options in when I make a new userprofile field ..
I am using 3.5.2 and the selcetions I have are this
TitleMax 50
DescriptionMax 250
Default ValueYou may specify a default value that is entered into this field at the time of registration.
Max length of allowed user input
Display Size
Profile Field Type
Single-Line Text Box
Multiple-Line Text Box
Display Order
Field Required
Field Editable by User
Private Field
Yes
No
Field Searchable on Members List
Yes
No
Show on Members List
Yes
No
Regular ExpressionYou may require the input field to match a regular expression (PCRE).
Rickie3
12-25-2005, 02:25 AM
make sure you select "Single Select Menu"
1. Go to AdminCP => Profile Fields => Add new Profile field => Single Select Menu
you appear to have selected single line text
Ole_Chilli
12-25-2005, 02:26 AM
make sure you select "Single Select Menu"
1. Go to AdminCP => Profile Fields => Add new Profile field => Single Select Menu
you appear to have selected single line text
see I told you I was an idiot
Rickie3
12-25-2005, 02:31 AM
see I told you I was an idiotwe are all in a learning world,merry xmas :banana: :banana:
Snake
12-25-2005, 10:58 AM
Thanks!
Lamby1973
12-26-2005, 07:20 AM
Thanks for helping out there Rickie! :) :D
Rickie3
12-26-2005, 07:27 AM
Thanks for helping out there Rickie! :) :Dno probs :)
Gripemaster
01-07-2006, 09:46 PM
*Clicks Install*
Thank you!
Sooner95
01-18-2006, 04:41 PM
Works great, included the State Of Confusion as well...thx! click
quanvo81
01-26-2006, 02:43 PM
Everything is ok, EXCEPT this:
The default option for everyone when they just signup and come to User CP and edit their profile is Au Aboriginal, so for people who is not familiar with Vbulletin setting, they will ignore it and when other members click on Member List, they will see alots of other members with the Au Aboriginal Flag.
I did choose the "Yes, Include the First Blank Option" already .
How do I fix this problem?
quanvo81
01-26-2006, 10:12 PM
Everything is ok, EXCEPT this:
The default option for everyone when they just signup and come to User CP and edit their profile is Au Aboriginal, so for people who is not familiar with Vbulletin setting, they will ignore it and when other members click on Member List, they will see alots of other members with the Au Aboriginal Flag.
I did choose the "Yes, Include the First Blank Option" already .
How do I fix this problem?
It's ok guys, I figured it out, just add an extra option to the field . I added Not Applicable to the top of the field, then rename the clear.gif file to Not Applicable.gif and reupload the the state directory.
thanks anyway guys...
napukjon
04-07-2006, 11:02 AM
Great work Lamby....works a treat...
rareclownfish
04-09-2006, 05:50 PM
On 3.5.4 should the default be set to: Yes, Icluding a first blank option?
Thanks, I might add this. :) I have the country and the state will go well...
SHalliday
06-28-2006, 01:12 PM
Now if I could only get province flags for Canada. Anyone know where I could get a set of those that I could use with this hack as well?
Mrdby
04-15-2007, 02:27 PM
3.6.5?
pompaunpo
06-04-2007, 01:55 PM
sorry... and flags in memberlist ?
I have activate : "Show on Member List " = YES
but in memberlist.php I see only Country name no image flag
Mrdby
06-05-2007, 12:25 AM
3.6.7?????
cloyal
06-29-2007, 12:15 AM
This works for 3.6.7PL. No problems. I installed this a while back on a 3.5 version and one of the states was misspelled. Not sure which one, but it wouldn't load the state or something. Can't remember but as soon as I find out, I'll post it here.
I enjoy this hack and so far no problems. I did make the changes to both the post bit and the post bit legacy, to be safe and have had no issues.
GremlinPrince
05-18-2008, 12:11 PM
thanks very much simple to use
Madlike
05-20-2008, 12:26 PM
Hey, Where is the Turkey fLag ?! :mad:
vBulletin® v3.8.12 by vBS, Copyright ©2000-2025, vBulletin Solutions Inc.