summaryrefslogtreecommitdiffstats
path: root/system
diff options
context:
space:
mode:
authorDerek Jones <derek.jones@ellislab.com>2009-02-05 17:54:58 +0100
committerDerek Jones <derek.jones@ellislab.com>2009-02-05 17:54:58 +0100
commit97707cc6e51d77ded02deba6d3d8d2c5867cab83 (patch)
tree49417ca758a0931526845d7f3738eaa36ff9ba1e /system
parent78a5fc973844c64fe9ead260948b85efaf680da9 (diff)
replaced $this->config-> with $CFG-> in ip_address()
Diffstat (limited to 'system')
-rw-r--r--system/libraries/Input.php6
1 files changed, 4 insertions, 2 deletions
diff --git a/system/libraries/Input.php b/system/libraries/Input.php
index 6491d1791..0679d0188 100644
--- a/system/libraries/Input.php
+++ b/system/libraries/Input.php
@@ -347,9 +347,11 @@ class CI_Input {
return $this->ip_address;
}
- if ($this->config->item('proxy_ips') != '' && $this->server('HTTP_X_FORWARDED_FOR') && $this->server('REMOTE_ADDR'))
+ $CFG =& load_class('Config');
+
+ if ($CFG->item('proxy_ips') != '' && $this->server('HTTP_X_FORWARDED_FOR') && $this->server('REMOTE_ADDR'))
{
- $proxies = preg_split('/[\s,]/', $this->config->item('proxy_ips'), -1, PREG_SPLIT_NO_EMPTY);
+ $proxies = preg_split('/[\s,]/', $CFG->item('proxy_ips'), -1, PREG_SPLIT_NO_EMPTY);
$proxies = is_array($proxies) ? $proxies : array($proxies);
$this->ip_address = in_array($_SERVER['REMOTE_ADDR'], $proxies) ? $_SERVER['HTTP_X_FORWARDED_FOR'] : $_SERVER['REMOTE_ADDR'];