pony

抄袭是一种美德

request.get获取参数

获取客户端的IP地址 :

String ip = request.getRemoteAddr();

获取服务器的名称和端口号:

String ip=request.getServerName();

String port=request.getServerPort();

获取UA :

String ua = request.getHeader("User-Agent");

获取来源:

String refer = request.getHeader("Referer");

获取内网IP:

String innerIP = request.getHeader("x-forwarded-for");

posted on 2009-03-11 16:22  马森  阅读(1223)  评论(0编辑  收藏  举报

导航