Skip to content

Commit

Permalink
Fixed "PHP Notice: Undefined index: HTTP_HOST"
Browse files Browse the repository at this point in the history
only in CLI mode
  • Loading branch information
pvolyntsev committed Jan 30, 2014
1 parent fa37011 commit ee68742
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions external/header.php
@@ -1,6 +1,7 @@
<?php
if (PHP_SAPI == 'cli') {
$_SERVER['REMOTE_ADDR'] = null;
$_SERVER['HTTP_HOST'] = null;
$_SERVER['REQUEST_URI'] = $_SERVER['SCRIPT_NAME'];
}

Expand Down

0 comments on commit ee68742

Please sign in to comment.