RSS DAILY NEWS TICKER EXAMPLE


home > overview

Arnold Daniels' Blog: Improve performace: check your loops




Arnold Daniels has a suggestion for developers out there to help improve the performance of their applications - check your loops.

So you have a script which is not performing the way you want to. The first thing you should do it try to find out what the problem is. There are some tools out there that can help you.

He mentions the profiler in Zend Studio as well as the one in XDebug. If you can't install those, however, he has another suggestion - FirePHP (a tool that can help time execution times in a simple and easy to include way.

With tools in hand, he offers a few suggestions as to what to check for and do in your applications:

  • Get the data ready before going into the loop
  • Don't do things in the loop, you can also do outside it
  • Use create_function to aid you
  • Be careful with abstraction in loops
  • Sometimes you can prevent loops altogether
  • Last resort: write an extension



click here to see original article or to find similar articles

 RSS DAILY HEADLINES

HEADLINES

Edwards to emerge from seclusion for speech

Aug. 9: Jennifer Palmieri, former staffer for John Edwards tells NBC's Jenna Wolfe that Elizabeth Edwards knew about her husband's affair since 2006, and is relieved the news is now public. (Today Show)In a return to the public stage, John Edwards has confirmed plans to talk politics a month after admitting to an extramarital affair. But his wife won't be at his side.


Australian police clear Indian doctor of involvement in terror (AFP)

Indian doctor, Mohamed Haneef, at a press conference in Bangalore in early August. Australian police have cleared Haneef of involvement in failed bomb attacks in Britain last year after a bungled 14-month probe(AFP/File/Dibyangshu Sarkar)AFP - Australian police have cleared an Indian doctor of involvement in failed bomb attacks in Britain last year after a bungled 14-month probe that is now the subject of a judicial inquiry.


Consumer spending flags, but confidence rises (Reuters)

A shopper walks past a store display in New York July 1, 2008. (Lucas Jackson/Reuters)Reuters - Personal income tumbled unexpectedly in July and inflation-adjusted spending shrank as government economic stimulus waned, but consumer spirits rose this month, a hint the economy may muddle through its woes.



Find this article in Google