System() and Exec() Not Working?
Posted: Tue Nov 09, 2010 7:55 pm
When executed from the terminal, the following command works perfectly:
gnuplot '/Applications/IPG/htdocs/ftp/company_name/Charts/gnuPlotCommandFile.gp'
However, when I run it from inside PHP with:
exec("gnuplot '/Applications/IPG/htdocs/ftp/company_name/Charts/gnuPlotCommandFile.gp'");
...or:
system("gnuplot '/Applications/IPG/htdocs/ftp/company_name/Charts/gnuPlotCommandFile.gp'");
...nothing seems to happen. How can I correct this?
Note - exec is enabled on my system, according to the following function:
function exec_enabled() {
$disabled = explode(', ', ini_get('disable_functions'));
return !in_array('exec', $disabled);
}
Thanks very much in advance to all for any info.
gnuplot '/Applications/IPG/htdocs/ftp/company_name/Charts/gnuPlotCommandFile.gp'
However, when I run it from inside PHP with:
exec("gnuplot '/Applications/IPG/htdocs/ftp/company_name/Charts/gnuPlotCommandFile.gp'");
...or:
system("gnuplot '/Applications/IPG/htdocs/ftp/company_name/Charts/gnuPlotCommandFile.gp'");
...nothing seems to happen. How can I correct this?
Note - exec is enabled on my system, according to the following function:
function exec_enabled() {
$disabled = explode(', ', ini_get('disable_functions'));
return !in_array('exec', $disabled);
}
Thanks very much in advance to all for any info.