|
Posted by news@celticbear.com on 04/27/06 18:33
I've a PHP script that does some stuff, zips up some files, and starts
an FTP process.
I need it to do the Zip and FTP in the background and let the page
finish, otherwise the user could have that page sitting there loading
for 20 minutes while the FTP completes.
Here's what I have:
$zipfile = $order_po.".zip";
exec("/var/www/html/services/ftp.sh $zipfile 2>&1 &", $output2,
$status);
echo "<div align='center' class='style1_hd'>Your auto-created ZIP file
is currently being sent through FTP!</div></body></html>";
exit();
?>
(The ftp.sh is the FTP logon and transfer script.)
As you can see I have the & to make it a background process, and
sending the stdoutput elsewhere.
Any ideas?
Thanks!
Liam
Navigation:
[Reply to this message]
|