ASP Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me

The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.

Go Back   Dev Shed ForumsProgramming Languages - MoreASP Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old December 12th, 2002, 11:53 AM
digital6 digital6 is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Dec 2002
Posts: 5 digital6 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
getting clients country

what is the easiest way to get the clients country, wthout asking them for it............is there a HTTP request?

Thanks

D6
Comments on this post
Gran Roguismo agrees!

Reply With Quote
  #2  
Old December 12th, 2002, 08:30 PM
a.koepke's Avatar
a.koepke a.koepke is offline
Second highest poster :p
Dev Shed God 5th Plane (7000 - 7499 posts)
 
Join Date: Jul 2001
Posts: 7,322 a.koepke User rank is Sergeant (500 - 2000 Reputation Level)a.koepke User rank is Sergeant (500 - 2000 Reputation Level)a.koepke User rank is Sergeant (500 - 2000 Reputation Level)a.koepke User rank is Sergeant (500 - 2000 Reputation Level)a.koepke User rank is Sergeant (500 - 2000 Reputation Level) 
Time spent in forums: 8 h 13 m 55 sec
Reputation Power: 31
The IP addresses are a location-less protocol and so there is no sure way of finding out what country a user is from. The only you can maybe do it is to do a dns lookup on the ip address and get the country code from the domain but that is not very reliable.
__________________
- Andreas Koepke

Koepke Photography


Reply With Quote
  #3  
Old December 12th, 2002, 08:56 PM
digital6 digital6 is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Dec 2002
Posts: 5 digital6 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
yeah...i was hoping there was another way......

Reply With Quote
  #4  
Old December 24th, 2002, 07:48 AM
Wingman Wingman is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Dec 2002
Location: Bavaria, Germany
Posts: 140 Wingman User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 3 h 40 m 41 sec
Reputation Power: 11
You can read out the HTTP Header "Accept Language". This field has a list of language codes prefered as a response to the request.

See http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html.

Example:

Accept-Language: da, en-gb;q=0.8, en;q=0.7

would mean: "I prefer Danish, but will accept British English and other types of English."

Reply With Quote
  #5  
Old December 27th, 2002, 01:59 PM
LavaCube LavaCube is offline
Just a kid
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Sep 2002
Location: Canada
Posts: 105 LavaCube User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 2 m 19 sec
Reputation Power: 11
Or you could just get them to fill out a form.
Comments on this post
Gran Roguismo agrees!
__________________
[ lavacube ]

My Personal Site[greyDistortion]

PHP version: 4.3.8
MySQL version: 4.0.21
Operating System (OS): SuSE Linux 9.1
Apache version: 2.0.50

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming Languages - MoreASP Programming > getting clients country

Developer Shed Advertisers and Affiliates



Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

© 2003-2013 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap