62,073
社区成员
发帖
与我相关
我的任务
分享
<%@ WebHandler Language="C#" Class="returnIp" %>
using System;
using System.Web;
public class returnIp : IHttpHandler {
public void ProcessRequest (HttpContext context) {
context.Response.ContentType = "text/plain";
context.Response.Write(context.Request.UserHostAddress);
}
public bool IsReusable {
get {
return false;
}
}
}
访问它就可以了。