I have a file called address.php with a few functions in it. I want to call a specific function in that file from the command line. How?
The name of the function is
Add this to the top of the file "/var/www/test/address.php"...
foreach ($argv as $i=>$arg ) { if ( $arg == "exportAddress" ) { exportAddress($argv[$i+1]); } }
Then from the command line, execute:
php /var/www/test/address.php exportAddress 12345