Hi,
I have an error when trying to upgrade , which relates to config.php
Please see code:
Line 12 and 13 of config are;
Any help would be appreciated.
Thank you
I have an error when trying to upgrade , which relates to config.php
Please see code:
Code:
An exception occurred: [ErrorException] [E_WARNING] Undefined array key "REMOTE_ADDR" in src/config.php on line 13
#0 src/config.php(13): XF::handlePhpError(2, '[E_WARNING] Und...', '/home/...', 13)
#1 src/XF/App.php(264): require('/home/wj...')
#2 src/XF/Container.php(33): XF\App->XF\{closure}(Object(XF\Container))
#3 src/XF/App.php(3834): XF\Container->offsetGet('config')
#4 src/XF/App.php(2228): XF\App->container('config')
#5 src/XF/Cli/App.php(25): XF\App->setup()
#6 src/XF.php(771): XF\Cli\App->setup(Array)
#7 src/XF/Cli/Runner.php(58): XF::setupApp('XF\\Cli\\App')
#8 cmd.php(17): XF\Cli\Runner->run()
#9 {main}
Line 12 and 13 of config are;
Code:
if (isset($_SERVER['HTTP_CF_CONNECTING_IP'])) { $_SERVER['REMOTE_ADDR'] = $_SERVER['HTTP_CF_CONNECTING_IP']; }
$_SERVER["REMOTE_ADDR"] = ( isset($_SERVER["HTTP_X_REAL_IP"]) ? $_SERVER["HTTP_X_REAL_IP"] : $_SERVER["REMOTE_ADDR"] );
Any help would be appreciated.
Thank you