dlf1987 Posted December 1, 2008 Share Posted December 1, 2008 I have a couple API's supplied from other sites that i have on one php page. Is there a way to give each API 45 secs to complete, otherwise continue to the next API on the page? I dont want the customer to know if they timeout. Thanks Link to comment https://forums.phpfreaks.com/topic/135027-timeout-help/ Share on other sites More sharing options...
gevans Posted December 1, 2008 Share Posted December 1, 2008 I'm not sre of the best way of doing this, but until someone else gives you a little help have you considered ajax. Pull in the API dynamically for a set amount of time, if it doesnt load move on javascript timer etc..? Link to comment https://forums.phpfreaks.com/topic/135027-timeout-help/#findComment-703296 Share on other sites More sharing options...
dlf1987 Posted December 1, 2008 Author Share Posted December 1, 2008 I really just wanted to keep it purely php. Also, it really just comes down to me not wanting the page to timeout on the customer leaving them sitting there with a timeout error and know where to go... It needs to pretty much ignore(or hide) the timeout error and continue on with the rest of the page. Link to comment https://forums.phpfreaks.com/topic/135027-timeout-help/#findComment-703310 Share on other sites More sharing options...
dlf1987 Posted December 1, 2008 Author Share Posted December 1, 2008 so i set it to set_time_limit(30); Know i don't want the customer too see "Fatal error: Maximum execution time of 30 second exceeded...". So how do i make it continue on to the next page? Any Help? Link to comment https://forums.phpfreaks.com/topic/135027-timeout-help/#findComment-703454 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.