confused by getClientIp()

Showing 1-2 of 2 messages
confused by getClientIp() Kris Wallsmith 1/11/12 12:23 PM
I am confused how the HttpFoundation\Request class’ static ::$trustProxy property interacts with the Boolean $proxy argument on the getClientIp() method. It looks like my application code needs to either always pass true as the first argument, or somehow be aware of whether it is behind a proxy. I would rather my application code not need to be aware of this.

My question is this: Is the $proxy argument on Request::getClientIp() still necessary in light of the newer static ::$trustProxy property?

Re: confused by getClientIp() Константин 2/4/12 9:22 AM