Added another method to determine client IP address

This commit is contained in:
Deon George 2016-08-03 14:05:14 +10:00
parent fd134e7f87
commit 6415652743

View File

@ -124,6 +124,11 @@ class Kohana_Request implements HTTP_Request {
unset($client_ips);
}
elseif (isset($_SERVER['HTTP_X_REAL_IP']))
{
// The remote IP address
Request::$client_ip = $_SERVER['HTTP_X_REAL_IP'];
}
elseif (isset($_SERVER['REMOTE_ADDR']))
{
// The remote IP address