title: how to get output of proc_open()
body: <p>I've tried to get output from <code>proc_open</code> method in php, but, when I print it, I got empty.</p>
  
  <pre>
  $descriptorspec = array(
      0 => array("pipe", "r"),
      1 => array("pipe", "w"),
      2 => array("file", "files/temp/error-output.txt", "a")
  );
  
  $process = proc_open("time ./a  a.out", $descriptorspec, $pipes, $cwd);
  </pre>
  
  <p>as long as I know, I can get the output with <code>stream_get_contents()</code></p>
  
  <pre>
  echo stream_get_contents($pipes[1]);
  fclose($pipes[1]);</pre>
  
  <p>But I can't do that..
  any suggestion?</p>
  
  <p>Thx before... </p>