标签:class blog http ext get string
//获取客户端、服务器、本地IP地址 public static string getIPAddress() { ////本地IP //string address = System.Net.Dns.GetHostAddresses(System.Net.Dns.GetHostName()).GetValue(2).ToString();//IP4 地址 ////本地电脑名称 //string addname = System.Net.Dns.GetHostName().ToString(); //客户端IP HttpRequest Request = HttpContext.Current.Request; string clientIP = Request.UserHostAddress; return clientIP; }
获取客户端、服务器、本地IP地址,布布扣,bubuko.com
标签:class blog http ext get string
原文地址:http://www.cnblogs.com/lengv10/p/3807740.html