I want to pass shell variables to a PHP script. This is my attempt:
var1=`echo name_16`
var2=`echo /home/place/end/name_16`
php script.php ${var1} ${var2}
These variables contain special characters [)(*&^%$#@!~<>_
] but no hyphens.
I am running PHP 4.3.9 cgi.
I attempt to pick up the variables in my PHP script thus:
$fish = $argv[1];
$sticks = $argv[2];
These variables come up as null. I've tried var_dump($argv);
and this returns null as well.
Am I passing these parameters correctly or am I missing something here?