lopolla Posted January 13, 2014 Share Posted January 13, 2014 (edited) I have a frontend page lets call is "front.php" and a backend page lets call it "backend.php". When I make actions I POST/GET data from front.php to backend.php, the script then runs (HTTP_REFERER) back to frontend.php. The problem is that sometimes I want to do quite time consuming actions in backend.php. Normally script has to end and afterwards refers you back to frontend.php. So the effect is that user have to wait for script to finish. Is there some way how I am able to make an actions in backend.php - start som sort of independent sub-proces/thread or similar - and return to front.php without waiting for backend.php to finish. My thought was that backend.php (the subproces/thread) could update database and then frontend.php could follow how the subproces/thread was doing.... Normally the time consuming handling consists of retrieving webpages on WWW and retrieve specific information which then is updated into a local database. Hope someone understands and is able to assist me If it is easy a short example would be extremly appriciated All the best! Edited January 13, 2014 by lopolla Quote Link to comment https://forums.phpfreaks.com/topic/285324-making-a-thread-or-similar-in-php/ Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.