News Feed
Sections




News Archive
Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

XPertDeveloper.com:
PHP coding tips for Performance Improvement
March 30, 2011 @ 10:35:14

The XPertDeveloper blog has shared some micro-optimization tips in a new post to their blog today. It's ten things you can do to squeeze that extra little bit out of your application's performance.

This post covers most performance improvement tips related to PHP coding. While working with small website or project it's ok to ignore these tips, but when you are dealing with large website or project which is going to maintained for long term and which have large number of user base. Developer must have to consider the below tips from the starting of the project.

Their tips include:

  • echo is more faster than print
  • Always use single quotes for long strings instead of double quotes. Because in double quotes it will search for php variable to evaluate them.
  • If you can declare a method as static then let it be
  • Try to minimize relative paths for files inclusion.

Keep in mind that these aren't a "silver bullet" for making your application run faster. These sorts of suggestions should only be applied after the major optimizations (caching with something like APC, good application structure) have been put in place. For most of these examples, you'll only really see an improvement if your application makes use of them heavily in a looping structure.

1 comment voice your opinion now!
performance microoptimization improvement opinion


blog comments powered by Disqus

Similar Posts

Volker Dusch: Please stop pretending PHP is a good language

Ivo Jansch's Blog: Good use of public, private and protected in OO class design

Mattias Geniar: The PHP circle: from Apache to Nginx and back

Java.Sys-con.com: Why Do 'Cool Kids' Choose Ruby or PHP to Build Websites Instead of Java?

Anthony Ferrara: Thoughts On PECL Frameworks


Community Events





Don't see your event here?
Let us know!


framework symfony api extension configure series laravel community conference podcast introduction composer tool list interview unittest opinion voicesoftheelephpant threedevsandamaybe release

All content copyright, 2015 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework