I do appreciate your reply. Yes, I've tried to track down the problem. I comment-out the fopen() function and use echo to display the URL. And it displays fine, so I did get the record from MySQL. Then when I put the fopen() back, same problem appears. I think it's probably because I have too much data to update at once, over a hundred maybe? Then it causes the PHP to timeout this script hence the error. If I can't solve this on PHP, I'll have to find an alternative way to do this...
Tony S. Wu [EMAIL PROTECTED] > On Saturday 08 June 2002 20:52, Tony wrote: >> You are being picky on me, huh? > > I'm sorry if you feel offended ... > >> I stated my problem 3 emails ago, > > ... but I delete mail from this list as soon as I've finished with them. As > you have started a new thread one would naturally assume this is a new > problem. Please don't expect people to remember dead threads. > >> browser gives me error "attempt to load >> "MyPage's URL" failed". > >> Could be because of execution timeout. >> I tried to set the time longer with no luck. >> If I put the flush() after each data, I get the first output only. >> But I need to update the database very often, and I don't want to do it by >> hands.. > > Have you tried tracking down where it is that the script fails? > > Either use echo() or error_log() at various points in the script to monitor > what the program is doing. For example before starting the while-loops > echo("Entering while loop") and inside the while-loop echo($counter), and > when the loop terminates echo someting to that effect. This should at least > tell you whether you have any infinite loops. > > Another thing you can do is simplify the check for the prices. Your present > method seems to be veru long-winded. I think a single preg_match() could > replace the "while ($counter < $i)" loop. -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php