vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 2.x Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=4)
-   -   Country Flag Hack v2.0 (https://vborg.vbsupport.ru/showthread.php?t=27485)

Kengan 09-23-2001 10:11 PM

Thanks ! COOL Hack ! I will try it tonight ! ;)

The Realist 10-06-2001 11:58 AM

In the Install instructions it states the below were it shows up twice.

I can only find it once in my user.php, can anyone help please.

Lost!

Brian

5 - Open admin/user.php

Find the FIRST line of this code (this shows up 2 times in user.cp):
makeinputcode("Birthday<br>(Format yyyy-mm-dd)","birthday");

Trillian 10-07-2001 03:14 PM

Realist,

Simply paste it after the first time you see it. It is true that the exact syntax of the code appears only once in the script. What the author was implying is that there is a second line in the script that looks very familiar to the first, and was trying to avoid confusion ;)

And to the author, GREAT WORK! My members are having a lot of fun with this hack :)

Delhaze 10-07-2001 09:02 PM

Quote:

Originally posted by Trillian
Realist,

Simply paste it after the first time you see it. It is true that the exact syntax of the code appears only once in the script. What the author was implying is that there is a second line in the script that looks very familiar to the first, and was trying to avoid confusion ;)

And to the author, GREAT WORK! My members are having a lot of fun with this hack :)

I dont thing thats correct, the second line that is similar also needs code to be added below it. Read the first page of the thread and it should be clearer.

jamesdasher 10-14-2001 01:26 AM

Okay, can somebody tell me what I did wrong...I wanted the large flags (provided by webhost) so I downloaded all the files unzipped them into the flags folder (at the same time erasing the original flags)...but...all the different pages are still trying to find the old image and saying 'not found'? Can anybody help?

James

aldamon 10-16-2001 12:38 PM

Hi,

The hack has been working great, but I thought you should know there's an error in your instructions. The flag for Great Britain, "Great Britain.gif", is referred to as "Great Britan.gif" (without the "I") in your instructions. You might want to change that. The flag obviously won't display without the change.

Thanks!

orca 10-16-2001 03:13 PM

Hi there,

here's what I did to display the flag in memberlist:

Open memberlist.php and find

PHP Code:

if ($userinfo[receivepm]) {
      eval(
"\$userinfo[pmlink] = \"".gettemplate("postbit_sendpm")."\";");
    } else {
      
$userinfo[pmlink] = "&nbsp;";
    } 

Just below it add

PHP Code:

// Country Hack
if (!$userinfo[country]) {
  
$flag "&nbsp;";
} else {
  
$Country=$post[country];
  
$Countryalt str_replace("%20"," ",$Country);
  
$flag "<img src=\"images/flags/$Country.gif\" alt=\"$Countryalt\" border=\"0\">";
}
// Country Hack End 

Now you need to modify memberlist and memberlistbit template.

In the template memberlist you need to increase the colspan of the td tag to 7:

PHP Code:

<td bgcolor="{ categorybackcolor }" colspan="7"><normalfont color="{ categoryfontcolor }"><b>$bbtitle Members List</b></normalfont></td

After you done that, insert

PHP Code:

<td bgcolor="{ tableheadbgcolor }" align="center"><smallfont color="{ tableheadtextcolor }"><b>Country Flag</b></smallfont></td

wherever you like. Be sure the remember where it was since you need to insert it at the same place in memberlistbit. E.g. if you add it after Email you need to put the following

PHP Code:

<td bgcolor="{ firstaltcolor }">$flag</td

just after

PHP Code:

<td bgcolor=" { secondaltcolor } ">$userinfo[useremail]</td

Please omit the spaces around the {} brackets. You may need to change the order of first- and secondaltcolor to get alternating colors.

Alternatively, you could leave memberlist alone and insert only $userinfo[country]. This will display the countries name.

DixonsNL 10-23-2001 06:20 PM

AJR, Your that man! ;) I got it running, and it works Perfect!! thnx m8! :) Keep the good hacks comming :D

Diva 10-25-2001 01:53 PM

Hi... I got the hack up and running. I love it! The problem? This guy tried to help with another, replaced my '.php' with the originals and now I can't seem to get the drop down box. I tried replacing all and basically starting over. The people who had flags still have them. I only see a section where the drop down box should be. Any suggestions? I love this hack!

Diva 10-26-2001 04:21 PM

Yay! It works! I don't know what I did, but I got it working! It looks great. Thanks AJR!

And thanks to Orca for the memberslist add on. It works like a charm!

On to tackle my next hack.
:eek:


All times are GMT. The time now is 01:19 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.01294 seconds
  • Memory Usage 1,758KB
  • 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_php_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)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