This means that argc / argv are not superglobals - they are visible only in the context of top-level PHP scripts, so ...
<?php $x = $argv[1]; // works class foo { function bar() { echo $argv[1]; // undefined } function baz() { global $argv; echo $argv[1]; // works } }
source share