Feb 15

The function ip2long() generates an IPv4 Internet network address from its Internet standard format (dotted string) representation. Why, because it has several advantages:
Read More



Feb 15

XCache is a fast, stable PHP opcode cacher that has been tested and is now running on production servers under high load. It overcomes a lot of problems that has been with other competing opcachers such as being able to be used with new PHP versions.

Read More



Dec 8

Here’s a simple script to get the total apache cpu and memory usage. Yes I could optimize my sed command…
Read More



Oct 23

MySQL has a nice tool called ‘mysqldumpslow’. It parses and summarizes the MySQL slow query log.

An interesting tool, however in most cases you’ll want to solve slow queries which reoccur the most, thus sorting the slow query log by count.
Read More



Sep 26

Many developers often forget to profile their code. Nevertheless this is a very important part of the software development cycle! It is much harder optimizing the code when it is already running in a production environment, while most of the problems could be avoided using a profiler or performance analyzer.
Read More



Aug 8

Concatenation can be optimized. Use the dot functionality instead of double quoting! Read More



Aug 8

$foo['bar'] is correct, while $foo[bar] is not.

When programming PHP code, always use quotes around a string literal array index because of 2 reasons. Read More