Reply to Re: Postponing execution time out

Your name:

Reply:


Posted by Alvaro G Vicario on 08/24/05 15:05

*** alex wrote/escribió (Tue, 23 Aug 2005 14:45:46 +0200):
> I've got a problem with a script that needs about 1 minute to run as the
> max_execution_time is set to 30 seconds only. I don't have the rights to
> modify the max_execution_time parameter on the server.

You may find this useful, if you're allowed to use it:

<?

ini_set('max_execution_time', 120); // 120 seconds
ini_set('memory_limit', '64M'); // 64 MB

?>


In either case, I highly recommend that you optimize your script. If it's a
database query, skip fields you don't need, limit returned rows to needed
records, use indexes, avoid unnecessary sortings... That can make as much
difference as going from 1 minute to 10 seconds.

--
-- Álvaro G. Vicario - Burgos, Spain
-- http://bits.demogracia.com - Mi sitio sobre programación web
-- Don't e-mail me your questions, post them to the group
--

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация