summaryrefslogtreecommitdiffstats
path: root/system/core/URI.php
diff options
context:
space:
mode:
authorPhil Sturgeon <email@philsturgeon.co.uk>2011-08-13 19:06:57 +0200
committerPhil Sturgeon <email@philsturgeon.co.uk>2011-08-13 19:06:57 +0200
commitc5dccf70ef6d8420b0b858f36318fc4375b0e25d (patch)
tree2eb565ec84a1103d2106e28d589cb68a9279bfb3 /system/core/URI.php
parentadd9ca05c17e5bfd17ded6a65b1a084f7da5d633 (diff)
Get php_sapi_name() == 'cli' involved in the 'is this the command line?' decision.
Diffstat (limited to 'system/core/URI.php')
-rw-r--r--system/core/URI.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/system/core/URI.php b/system/core/URI.php
index d56548654..20f0f006b 100644
--- a/system/core/URI.php
+++ b/system/core/URI.php
@@ -62,7 +62,7 @@ class CI_URI {
if (strtoupper($this->config->item('uri_protocol')) == 'AUTO')
{
// Is the request coming from the command line?
- if (defined('STDIN'))
+ if (php_sapi_name() == 'cli' or defined('STDIN'))
{
$this->_set_uri_string($this->_parse_cli_args());
return;