View Full Version : Country Flag Hack v2.0
Ninth Dimension
07-01-2003, 08:12 AM
06-29-03 at 02:59 AM ajk said this in Post #247 (https://vborg.vbsupport.ru/showthread.php?postid=413793#post413793)
The users at Drumsmith.com really like the Country Flag hack.
Is there a way I can use the small flags in one place, then use the large in another?
Thanks This is easy in theory, but will require some hard coded changes.
Basicly you find a 2nd set of flags, all with the same file names as the small set only with something like "big_" tapped onto the front of the filename, or maybe save the flags on your server space in a diffrent location (such as "images/largeflags/").
Once you have the files you need to find the file that controls whichever flag you want to be displayed as large. lets say for example it's the postbit flag you want displayed large, you need to open admin/functions.php and search for the following line: $flag = "<img src=\"images/flags/$Country.gif\" alt=\"$Countryalt\" align=\"absmiddle\" border=\"0\">";All you need to do then is edit the line to point to your large image (be it adding the big_ or changing the path, etc..)
I hope this helps? Personally I recomend looking at the install file again and using it to make your edits, then sinatlling them, just be careful not to add/remove any needed quote marks.
good luck.
Ninth Dimension
07-10-2003, 01:13 PM
I've noticed at least one flag is missing (maybe more) so i've decided to upload it here...
just download the image and save to your flag images directory. (you might need to rename it Europe.gif with a capital E).
Alien
07-10-2003, 07:26 PM
Anyone ever figure out how to get this to display on the forumhome? :)
Ninth Dimension
07-10-2003, 08:14 PM
Today at 09:26 PM Alien said this in Post #253 (https://vborg.vbsupport.ru/showthread.php?postid=416773#post416773)
Anyone ever figure out how to get this to display on the forumhome? :) get what to display? not much point in showing the user there own country flag because they already know it :p
Bulleh
07-18-2003, 04:17 PM
strange but Wen i go to USER CP , and edit profile i can change my flag
but normall users cant, why is this?
Kane Da Don
07-31-2003, 03:05 AM
great hack i installed it but for some reason it wont show in the postbit at all it shows in the getinfo and in the members but not in the postbit is their a way around this i put it in version 2.3.0
Alien
07-31-2003, 07:10 PM
07-10-03 at 05:14 PM Ninth Dimension said this in Post #254 (https://vborg.vbsupport.ru/showthread.php?postid=416782#post416782)
get what to display? not much point in showing the user there own country flag because they already know it :p
Well... umm... aww crumbs! ;)
but what if everyone had a short-term memory and needed to be reminded? Yeah that's it!
CRego3D
08-30-2003, 11:50 PM
06-16-03 at 01:29 PM CRego3D said this in Post #238 (https://vborg.vbsupport.ru/showthread.php?postid=409591#post409591)
One last request :)
http://www.linuxcult.com/forum/memberlist.php?&what=datejoined
as you see, the "distro" images is where the flags woudl be .. is there a way I can "sort" by them ? :)
love this hack .. hehe
bump ? :)
basically, how can i "sort by country/flag" in the memberlist.php ..
Logtenberg
09-09-2003, 10:00 PM
I upgraded my board to 2.3 from 2.03 and I had the country flag hack installed on my old version.
So all I did to get this this hack to work was change the code on the php pages and upload.
Now I get:
Parse error: parse error, expecting `T_STRING' in /home/ryan/public_html/forum/admin/functions.php on line 2248
Warning: Cannot modify header information - headers already sent by (output started at /home/ryan/public_html/forum/admin/functions.php:2248) in /home/ryan/public_html/forum/admin/functions.php on line 1668
Fatal error: Call to undefined function: set_bbarraycookie() in /home/ryan/public_html/forum/showthread.php on line 265
-----------------------
One thing I also noticed while doing the search and replace,
was that in member.php the code that to replace didn't match the code in the instruction file i.e.:
find:
$templatesused .= "register_birthday,modifyprofile_custo....
on my member.php this line reads:
$templatesused = 'register_birthday,modifyprofile_custo...
Notice the missing period on my member.php
I went ahead and replaced this code anyways... could this be the problem? do I need to remove the period?
----------------------
UPDATE:
I removed the country flag hack code from member.php and uploaded it. The above error no longer appeared, in the postbits the flag for each member appeared properly, the registration process worked with the flag... So I know the problem must be with the code on member.php
Thanks
reismarktq2
09-11-2003, 02:44 PM
My users are having a problem where the flags they've purchased (I'm using Lesane's Store Hack and the flag add-on in conjunction with this hack) are disappearing at random intervals. I have no idea what's causing it. Some people are saying it happens when they update their profiles; others say it's also happening at other times.
I'm running vB 2.3.0 and in addition to the store stuff, I've also added a bunch of flags to the original set (including some customs and the entire set of U.S. states).
Can anyone help out?
Logtenberg
09-17-2003, 08:24 PM
I upgraded my board to 2.3 from 2.03 and I had the country flag hack installed on my old version.
So all I did to get this this hack to work was change the code on the php pages and upload.
Now I get:
Parse error: parse error, expecting `T_STRING' in /home/ryan/public_html/forum/admin/functions.php on line 2248
Warning: Cannot modify header information - headers already sent by (output started at /home/ryan/public_html/forum/admin/functions.php:2248) in /home/ryan/public_html/forum/admin/functions.php on line 1668
Fatal error: Call to undefined function: set_bbarraycookie() in /home/ryan/public_html/forum/showthread.php on line 265
-----------------------
One thing I also noticed while doing the search and replace,
was that in member.php the code that to replace didn't match the code in the instruction file i.e.:
find:
$templatesused .= "register_birthday,modifyprofile_custo....
on my member.php this line reads:
$templatesused = 'register_birthday,modifyprofile_custo...
Notice the missing period on my member.php
I went ahead and replaced this code anyways... could this be the problem? do I need to remove the period?
----------------------
UPDATE:
I removed the country flag hack code from member.php and uploaded it. The above error no longer appeared, in the postbits the flag for each member appeared properly, the registration process worked with the flag... So I know the problem must be with the code on member.php
Thanks
UPDATE 2:
I found out about the period problem in a previous post and therefore made the necessary changes to the member.php code. The only problem I'm getting now is when someone attempts to edit their profile. The following error occurs:
Fatal error: Call to undefined function: show_nopermission() in /home/ryan/public_html/forum/member.php on line 242
Please Help!
reismarktq2
09-30-2003, 12:00 AM
BUMP... please help!
Logtenberg
10-31-2003, 12:43 AM
How would you search users by where their from (country flag)? What's the variable that needs to be used?
Thanks
Kohhal
01-21-2004, 07:30 AM
This is the greatest hack I have on my forums, is anyone working on a version for vBulletin3???
Found it here! (http://www.vbulletintemplates.com/mods/showthread.php?t=4113) :D
FutureDEV
06-07-2004, 08:57 PM
Where can I get the vb3 version of this hack? Thanks!
Kohhal
06-08-2004, 08:53 AM
<a href="https://vborg.vbsupport.ru/showthread.php?t=60538" target="_blank">https://vborg.vbsupport.ru/showthread.php?t=60538</a>
FutureDEV
06-08-2004, 07:54 PM
Thanks, Ill check it out.
Snake
06-12-2005, 12:30 PM
Nevermind. Found it!
vBulletin® v3.8.12 by vBS, Copyright ©2000-2025, vBulletin Solutions Inc.