php exec外部命令如何获取pid?
网友回复
<?php $command = $yourCommand.' > /dev/null 2>&1 & echo $!'; exec($command ,$output); $pid = (int)$op[0]; ?>
php exec外部命令如何获取pid?
网友回复
<?php $command = $yourCommand.' > /dev/null 2>&1 & echo $!'; exec($command ,$output); $pid = (int)$op[0]; ?>