ajax - Jquery load() live results? -
i have simple page when submit button clicked load page using load()
eg:
$("#res").load("do.php"); do.php contains few simple command run , return results screen.
if run do.php directly in browser results displayed on screen in real time script runs , gets results back.
however when called page using load() results page once do.php has finished.
is there way call do.php page , have results returned live ?
do.php contains simple commands similar to:
<?php $cmd = 'ping 127.0.0.1'; while (@ ob_end_flush()); $proc = popen($cmd, 'r'); echo '<pre>'; while (!feof($proc)) { echo fread($proc, 4096); @ flush(); } echo '</pre>'; ?>
Comments
Post a Comment