note 100523 modified in reserved.variables.argc by danbrown
| From: | danbrown@php.net | Date: | Thu, 21 Oct 2010 13:23:13 +0000 |
| Subject: | note 100523 modified in reserved.variables.argc by danbrown | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-173343@lists.php.net to get a copy of this message | ||
I use the following lines to check if i'm using CLI mode or not :
<?php
$cli_mode = false;
if ( isset($_SERVER['argc']) && $_SERVER['argc']>=1 ) {
$cli_mode = true;
}
?>
--was--
I use the following lines to check if i'm using CLI mode or not :
$cli_mode = false;
if ( isset($_SERVER['argc']) && $_SERVER['argc']>=1 ) {
$cli_mode = true;
}
http://php.net/manual/en/reserved.variables.argc.php