vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB4 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=251)
-   -   IP to flag/country (https://vborg.vbsupport.ru/showthread.php?t=258903)

lmgc 02-15-2011 11:43 AM

IP to flag/country
 
Hello vb's

is there any way to detect automaticly the user's country and show a flag for that in the profil ?

your24hourstore 02-15-2011 11:54 AM

there is a mod that shows the flag of the country of the register, and you could make them select their country , although they could lie, but a flag is displayed in the postbit legacy area of the posts, you would then be able to double check them by grabbing their IP and checking it against the list using a site like this one

or this one you could even edit the php file that is in that mod to reflect the ip of the country in the postbit legacy also, but you will need a list of each and every Ip used by a country , or that is on your server.
it would be daunting here is a command line input command that will ping

Open Command Prompt and type:
Code:

FOR /L %i IN (1,1,254) DO ping -n 1 192.168.0.%i | FIND /i "Reply">> c:\ipaddresses.txt
The "-n 1" is for only 1 ping packet to be sent to each computer.
Change 192.168.0 to match you own Network ID.
This will ping all IP addresses on the 192.168.0.0 network segment and create a text file called IPADDRESSES.TXT in C:\, where it will list only the IP addresses that gave a reply. this may work to do what I have said here but would have to be done every once in a while then added to the list IPADDRESSES.TXT

lmgc 02-15-2011 03:59 PM

thank you man,

are you talking about this mod :
https://vborg.vbsupport.ru/showthread.php?t=229511

your24hourstore 02-15-2011 06:20 PM

Quote:

Originally Posted by lmgc (Post 2162862)
thank you man,

are you talking about this mod :
https://vborg.vbsupport.ru/showthread.php?t=229511

yes that's it, i actually modified it to do states instead of country's :)

brihan 02-22-2013 08:33 PM

Quote:

Originally Posted by your24hourstore (Post 2162906)
yes that's it, i actually modified it to do states instead of country's :)

Hi Your24HourStore,

Would you mind sharing how your modified it to do state flags rather than country flags?

Thanks!

Brian

brihan 03-06-2013 06:59 PM

Hi,

I have tried to contact your24hourstore to see how he/she was able to make it show state flags rather than country flags but he/she does not accept email or PM from this site.

Can anyone else help me with this?

Thank you,

Brian

Krusty1231 03-07-2013 11:29 AM

If you wanted state icons instead of country icons you would follow the exact same steps as in the mod link https://vborg.vbsupport.ru/showthread.php?t=229511

You would of course need to find state flags: http://www.google.com/search?q=state...w=1280&bih=909

You would follow the same steps as in the mod link -

Quote:

Title = STATE Flag
Description = Add your STATE flag to your profile:
Profile Field Category = (Uncategorized)
Options = Copy & Paste the Whole contents of the file attached below (OPTIONS)
Set Default = None
Display Order = You Select this (dependant on how many you already have)
Field Required = yes, at registration and profile updating
Field Editable by User = Yes
Private Field = No
Field Searchable on Members List = No
Show on Members List = Yes
You would need to create a list of STATES and copy that in the options of the User Profile field instead of using the flag one provided.

I hope that makes sense.


All times are GMT. The time now is 03:32 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.01205 seconds
  • Memory Usage 1,725KB
  • 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
  • (3)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (7)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
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete