标签:java ip
直接上代码了:
String ip = null;
if (request.getHeader("X-Real-IP") == null) {
ip = request.getRemoteHost();
} else {
ip = request.getHeader("X-Real-IP");
}
java 获取客户端的真实ip
原文地址:http://blog.csdn.net/u010670689/article/details/45889995