检测访客的城镇和国家 [英] Detect Visitor's Town and Country
问题描述
我去过一些网站,它显示了城镇,州(如果美国),
国家我正在浏览。现在,我知道检测国家很容易,但
你如何确定城镇?
ASP组件有什么用呢?
谢谢,
比尔。
I''ve been to a few websites where it displays the town, state (if USA),
country I''m browsing from. Now, I know that detecting country is easy, but
how do you determine the town?
What ASP components do this?
Thanks,
Bill.
推荐答案
没有保证这样做的方式...
最好你可以做到这一点获得用户IP并做一些地理查找但是即使这些
也不准确,他们会只为用户提供ISP的位置
最好.....
你可能想重新考虑你想要做的事情。,
-
Curt Christianson
网站&脚本: http://www.Darkfalz.com
博客: http://blog.Darkfalz.com
"维克多" < BL *** @ blank.com>在消息中写道
新闻:OL ************* @ tk2msftngp13.phx.gbl ...
there is no guaranteed way of doing this...
Best you can do it get the users IP and do some geo-lookups but even these
aren''t accurate, they will only get you a location for the users ISP at
best.....
You may want to rethink what you are trying to do.,
--
Curt Christianson
Site & Scripts: http://www.Darkfalz.com
Blog: http://blog.Darkfalz.com
"Victor" <bl***@blank.com> wrote in message
news:OL*************@tk2msftngp13.phx.gbl...
我去过一些网站,它显示了城镇,州(如果美国),
国家我正在浏览。现在,我知道检测国家很容易,但是你如何确定这个城镇?
ASP组件做了什么?
谢谢,
比尔。
I''ve been to a few websites where it displays the town, state (if USA),
country I''m browsing from. Now, I know that detecting country is easy, but
how do you determine the town?
What ASP components do this?
Thanks,
Bill.
http://www.countryhawk.com/
-
这是我的签名。这是一般提醒。
请发布DDL,样本数据和所需结果。
参见 http://www.aspfaq.com/5006 获取信息。
" Victor" < BL *** @ blank.com>在消息中写道
新闻:OL ************* @ tk2msftngp13.phx.gbl ...
http://www.countryhawk.com/
--
This is my signature. It is a general reminder.
Please post DDL, sample data and desired results.
See http://www.aspfaq.com/5006 for info.
"Victor" <bl***@blank.com> wrote in message
news:OL*************@tk2msftngp13.phx.gbl...
我去过一些网站,它显示了城镇,州(如果美国),
国家我正在浏览。现在,我知道检测国家很容易,但是你如何确定这个城镇?
ASP组件做了什么?
谢谢,
比尔。
I''ve been to a few websites where it displays the town, state (if USA),
country I''m browsing from. Now, I know that detecting country is easy, but
how do you determine the town?
What ASP components do this?
Thanks,
Bill.
Victor于2005年4月11日在microsoft.public.inetserver.asp.general写道:
Victor wrote on 11 apr 2005 in microsoft.public.inetserver.asp.general:
我去过一些网站,它显示了城镇,州(如果是美国),我正在浏览的国家。现在,我知道检测国家很容易,但是你如何确定这个城镇?
ASP组件是做什么的?
I''ve been to a few websites where it displays the town, state (if
USA), country I''m browsing from. Now, I know that detecting country is
easy, but how do you determine the town?
What ASP components do this?
你不需要一个组件,
只是问用户,
所有其他方法都经常不正确。
数百万用户将保证此代码是正确的:
<%
a = 7
如果a< 8那么
%>你住在纽约,纽约<%
其他
%>你死了< %
结束如果
%>
-
Evertjan。
荷兰。
(请在我的电子邮件地址中将x'变为点数)
You do not need a component,
just ask the user,
all other methods being incorrect more often than not.
Millions of users will vouch this code as being correct:
<%
a=7
if a<8 then
%>You live in the New York, NY<%
else
%>You are dead<%
end if
%>
--
Evertjan.
The Netherlands.
(Please change the x''es to dots in my emailaddress)
这篇关于检测访客的城镇和国家的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!