Re: Echo from stream_select as output is generated by child process?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Great feedback from all of you so far!

In the meantime, here is the SO link: http://stackoverflow.com/questions/23945328/multiple-stream-select-with-proc-open-receive-responses-from-slow-process


On Jun 5, 2014, at 6:13 PM, Christoph Becker wrote:

> Mike Kilmer wrote:
> 
>> I'm using proc_open to call a python script.
>> 
>> The (python) child process takes about a minute to run, and when run
>> from the command line it prints results as they are completed.
>> 
>> With the php script, it just prints them all when it's complete.
>> 
>> Is there a way to return the python output to the browser in real
>> time?
> 
> Have you tried running the PHP script from the command line?  It might
> be possible that the PHP script echoes the output of the Python script
> "immediately", but that PHP's output is buffered by the webserver or
> somehow "delayed" by the browser.
> 
>> The full script is posted on StackOverflow, and what I think are the
>> relevant segments are below:
> 
> It might be useful to post a link to the StackOverflow topic.
> 
> -- 
> Christoph M. Becker


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php






[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux