如何在struts2动作方法中获取客户端IP地址?(How to get the client IP address inside struts2 action method?)
有没有办法在struts2动作方法中获取客户端的IP地址?
我已经实现了SesionAware和RequestAware接口,但这两个接口只注入会话和请求映射。
Is there a way to get the client's IP address inside an struts2 action method?
I have implemented both SesionAware and RequestAware interfaces, but these two inject only the session and request maps.
最满意答案
你试过ServletRequestAware吗?
Have you tried ServletRequestAware?
更多推荐
发布评论