This approach is not very efficient, if used in the web, if used less can be used in this way, if used, or recommend the use of IP library
Copy Code code as follows:
#region # #得到真实IP以及所在地详细信息
Get real IP and location details
ArticleDirectory
Comment
Webbupload Upload Component
FeaturesYou can configure the Web. config file to set the size of the uploaded file.It is fully developed Based on. NET and does not require any client configuration.Provides
This method is not efficient. If it is used in the WEB, you can use this method if it is rarely used. If it is commonly used, it is recommended to use the IP library.Copy codeThe Code is as follows:# Region # obtain the real IP address and location
Implementation Method: capture IP addresses through regular expressions to display website data ....
Friendly reminder: This method is not highly efficient. If it is used in the Web, you can use this method if it is rarely used. If it is
Country
Enables the MS-DOS subsystem to use international time, date, currency, case conversions, and decimal separators.
Grammar
Country=xxx[,[yyy][,[drive:][path] [FileName]]
Parameters
Xxx
Specifies the country/region code.
yyy
Specifies the
Country
Enables the MS-DOS subsystem to use international time, date, currency, case-insensitive conversion, and decimal delimiters.
SyntaxCountry = xxx [, [YYY] [, [drive:] [path] filename]
ParametersXxxCountry (region)Code.YyySpecifies the
Java with the tool class enough, download and install QQ, and then search the installation directory under the Loclist.xml fileHere is the code to parse the file, output as a bunch of SQL, you know, if you want the JSON objectThen change the
This article provides a detailed analysis of the implementation of php based on ip address query in the region where it is located. if you need a friend, refer to the dat file and the information file about the ip address corresponding to the region.
Dat file, information file about the ip corresponding region
Qqwry. dat file
Download it online by yourself
Class file, parse the qqwry. data FileIpLocation. php fileCopy codeThe Code is as follows: Class IpLocation {/*** @ Var resource
How to block network traffic in Linux based on country location
As a system administrator who maintains a Linux production server, you may encounter the following situations: You need to selectively block or allow network traffic to pass through
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.