chiprivers Posted March 21, 2007 Share Posted March 21, 2007 I have been working on a script for a couple of days and I thought I had finally completed it but it seems to be stopping for no reason? Is there a limit on the running time for a script or the size of the html page it can generate? The script grabs the source from a webpage off thw web and extracts some data from the page and also a series of sub pages linked from it. It takes all this data, checks whether it is already in my database and adds if it is not going to duplicate anything. All of this bit works fine but it was the last bit that I have just completed which seems to be making the script stall half way through. The data is listed over several pages with a next page link at the bottom. The script checks to see if there is a next button and if so loops back through the script for the next page. When I run the script with this addition, it stalls half way through the second page. If I let the script run and comment out all the processing part of the script, it works fine and loops through all of the pages? Any ideas?? Link to comment https://forums.phpfreaks.com/topic/43694-solved-limit-to-script-size-or-running-time/ Share on other sites More sharing options...
per1os Posted March 21, 2007 Share Posted March 21, 2007 http://us2.php.net/manual/en/function.set-time-limit.php set_time_limit(500); //sets it to 500 seconds. Link to comment https://forums.phpfreaks.com/topic/43694-solved-limit-to-script-size-or-running-time/#findComment-212094 Share on other sites More sharing options...
chiprivers Posted March 21, 2007 Author Share Posted March 21, 2007 http://us2.php.net/manual/en/function.set-time-limit.php set_time_limit(500); //sets it to 500 seconds. Thats done it, thanks Link to comment https://forums.phpfreaks.com/topic/43694-solved-limit-to-script-size-or-running-time/#findComment-212103 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.