PHP pclose() 函数

定义和用法
pclose() 函数关闭由 popen() 打开的管道。
语法
pclose(pipe)
参数 | 描述 |
---|---|
pipe | 必需。规定由 popen() 打开的管道。 |
说明
该函数返回运行的进程的终止状态。
若出错,则返回 false。
例子
<?php
$file = popen("/bin/ls","r");
//一些要执行的代码
pclose($file);
?>
$file = popen("/bin/ls","r");
//一些要执行的代码
pclose($file);
?>
