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

Adam Culp:
XHProf PHP Profiling
Aug 05, 2013 @ 09:03:35

Adam Culp has posted to his site about some of his experiences with XHProf and profiling his PHP applications.

Today I set up my development environment so I can use XHProf to profile PHP scripts when needed, and it was pretty easy. [...] XHProf is a PECL package, and can be easily installed by using standard PECL commands.

He walks you through the installation of the PECL package (you'll need to use the command line for this one) and how to add the module to your php.ini to enable it. Once you restart your web server, you can start the debugging using the xhprof_enable function and then the xhprof_disable function to end the testing and retrieve the data for processing. He also includes a bit of output from his own pass-through script to show the results.

tagged: xhprof profiling install tutorial debug

Link: http://www.geekyboy.com/archives/718

Kenny Katzgrau's Blog:
Enable Site-Wide Profiling With CodeIgniter
Dec 30, 2010 @ 09:07:33

On his blog today Kenny Katzgrau talks about a handy feature of the CodeIgniter framework - profiling - and how you can implement it site-wide rather than just on a controller by controller basis.

In your controller before you load a view, CodeIgniter will give you information regarding how fast the page loaded, how many SQL queries executed, the content of each query, and the running time of each query. This is incredibly useful when you are trying to debug your application, or simply see how quickly things are loading. There’s only one problem: To enable profiling, that line of code above must be present. What if you want to profile several pages, or even your whole web application?

He turned to another built-in feature of the framework, the controller hooks it allows, to set up a simple post-controller execution that gets a new CodeIgniter instance and enables the profiling configuration item. This is a much better option than having to put the line in each and every controller and method he might want profiled.

tagged: sitewide profiling codeigniter framework tutorial

Link:

ThinkPHP Blog:
Benchmarking & optimizing real-world scenarios in a business context
Jun 18, 2010 @ 09:14:35

On the ThinkPHP blog today there's a new article looking at some of the best practices they seen when it comes to profiling and benchmarking your PHP-based applications.

Over the years, PHP has evolved from a script language to a programming language used in big applications with high-level architectures. As the most popular language for web applications, PHP is very fast, robust and stable by default. Coming from tiny scripts, PHP is used in large-scale web applications nowadays. In terms of business context, we need to focus on these three key factors: Scalability, Responsiveness and Resource misusage. All three factors have a high impact on hardware costs, customer loyalty and - indirectly - sales.

They mention a few ways that you can use to optimize your application's code including evaluating resource limitations, Firebug caching results and finding bottlenecks with something like XDebug.

tagged: profiling benchmarking optimizing business

Link:

ProPHP Podcast:
Newscast for Dec 12th, 2007
Dec 25, 2007 @ 08:13:00

The Pro::PHP Podcast has released their latest episode - the Newscast for December 20th, 2007.

Topics mentioned include:

To grab this latest show you can either subscribe to their feed or you can just get the latest show via a direct mp3 download.

tagged: podcast newscast prophp phpcity java charting google profiling podcast newscast prophp phpcity java charting google profiling

Link:

ProPHP Podcast:
Newscast for Dec 12th, 2007
Dec 25, 2007 @ 08:13:00

The Pro::PHP Podcast has released their latest episode - the Newscast for December 20th, 2007.

Topics mentioned include:

To grab this latest show you can either subscribe to their feed or you can just get the latest show via a direct mp3 download.

tagged: podcast newscast prophp phpcity java charting google profiling podcast newscast prophp phpcity java charting google profiling

Link:

Gergely Hodicska's Blog:
What is new in PHP 5.3 - Part 4
Nov 20, 2007 @ 09:38:00

Gergely Hodicska has posted part four of his "what's new in PHP 5.3" series - a sort of "wrapup" for some of the smaller features that have been added. Among them are:

  • __callStatic
  • OpenID support
  • user.ini user defined ini functionality
  • dynamic static calls
  • XSLT profiling

...and many more. Check out the post for more to add to the list and for some brief examples of the ones already mentioned.

tagged: callstatic openid xslt profiling userini new php5 callstatic openid xslt profiling userini new php5

Link:

Gergely Hodicska's Blog:
What is new in PHP 5.3 - Part 4
Nov 20, 2007 @ 09:38:00

Gergely Hodicska has posted part four of his "what's new in PHP 5.3" series - a sort of "wrapup" for some of the smaller features that have been added. Among them are:

  • __callStatic
  • OpenID support
  • user.ini user defined ini functionality
  • dynamic static calls
  • XSLT profiling

...and many more. Check out the post for more to add to the list and for some brief examples of the ones already mentioned.

tagged: callstatic openid xslt profiling userini new php5 callstatic openid xslt profiling userini new php5

Link:

Christian Stocker's Blog:
Added xslt profiling to PHP 5.3 and 6 CVS
Oct 02, 2007 @ 08:45:00

Christian Stocker briefly mentions a new addition he's made to the post-PHP5.3 branching of the main trunk of the PHP development - XSLT profiling.

After PHP 5.3 was branched (for making place for - among other new stuff - namespaces), it was finally time to put my XSLT profiling addition into the official PHP sources.

The addition allows you to check in on your XSLT translations and see which spots in it are taking the most time to parse. This can be a very valuable tool when trying to see into the "black box" that PHP has around XSLT transformations. PHP 5.2ers can get the same functionality with this patch too.

tagged: xslt profiling php5 cvs support extension xslt profiling php5 cvs support extension

Link:

Christian Stocker's Blog:
Added xslt profiling to PHP 5.3 and 6 CVS
Oct 02, 2007 @ 08:45:00

Christian Stocker briefly mentions a new addition he's made to the post-PHP5.3 branching of the main trunk of the PHP development - XSLT profiling.

After PHP 5.3 was branched (for making place for - among other new stuff - namespaces), it was finally time to put my XSLT profiling addition into the official PHP sources.

The addition allows you to check in on your XSLT translations and see which spots in it are taking the most time to parse. This can be a very valuable tool when trying to see into the "black box" that PHP has around XSLT transformations. PHP 5.2ers can get the same functionality with this patch too.

tagged: xslt profiling php5 cvs support extension xslt profiling php5 cvs support extension

Link:

php|architect:
August 2007 Issue Released
Aug 17, 2007 @ 09:32:00

php|architect magazine has released their latest issue - the August 2007 edition. The cover story for this month is a piece by Dirk Merkel covering the automation and benchmarking/code profiling of your application to find potential issues before your customers/users do.

Other great articles in this issue include:

  • a look at Flex and the Zend Framework
  • part one of a series on normalization (Chinese)
  • using cURL to extract pages and their data
  • "The Job Interview" - an insiders guide.

There's two ways to get this issue - you can either subscribe to the magazine for a year (the PDF edition is only $40 USD) or you can buy the single issue for about $5 USD.

tagged: phparchitect issue release benchmarking profiling phparchitect issue release benchmarking profiling

Link: