<?xml version="1.0"?>
<rss version="2.0">
  <channel>
    <title>PHPDeveloper.org</title>
    <link>http://www.phpdeveloper.org</link>
    <description>Up-to-the Minute PHP News, views and community</description>
    <language>en-us</language>
    <pubDate>Mon, 20 May 2013 08:13:57 -0500</pubDate>
    <ttl>30</ttl>
    <item>
      <title><![CDATA[DevShed: Benchmarking Applications with PHP]]></title>
      <guid>http://www.phpdeveloper.org/news/10026</guid>
      <link>http://www.phpdeveloper.org/news/10026</link>
      <description><![CDATA[<p>
DevShed has posted <a href="http://www.devshed.com/c/a/PHP/Benchmarking-Applications-with-PHP/">the first part</a> of a new series looking at benchmarking performance in your PHP applications.
</p>
<blockquote>
If you're anything like me, you have had your head spinning with questions [...] these and other dilemmas (add your own to the list) sometimes make peace of mind a nearly impossible goal.
</blockquote>
<p>
<a href="http://www.devshed.com/c/a/PHP/Benchmarking-Applications-with-PHP/">The tutorial</a> talks about a few simple methods for running benchmark data including the use of microtime(), an OOP method and wrapping the call inside a method of their class.
</p>]]></description>
      <pubDate>Wed, 23 Apr 2008 21:02:17 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Hasin Hayder's Blog: Counting occurrence of a word in a String - Benchmarking of PHP functions]]></title>
      <guid>http://www.phpdeveloper.org/news/7732</guid>
      <link>http://www.phpdeveloper.org/news/7732</link>
      <description><![CDATA[<p>
In an effort to add to the ever-growing list of "keeping it simple" benchmarks out there, <i>Hasin Hayder</i> presents <a href="http://hasin.wordpress.com/2007/04/30/counting-occurrence-of-a-word-in-a-string-benchmarking-of-php-functions/">his own results</a> for the task of fining the number of times a word occurs in a given string.
</p> 
<blockquote>
Today I was just thinking what are the possible ways to count the occurrence of a specific word inside a string. I found some possible ways finally and I just benchmarked them. Wanna see the result?? - for sure you will find it interesting too.
</blockquote>
<p>
Methods range from a simple split() and count() call out to using the regular expression functions to locate the matches. After running it four times (to check for accuracy), he the stats were pretty much the same. It looks like the substr+count method was the fastest overall with last place falling to the array function method.
</p>]]></description>
      <pubDate>Mon, 30 Apr 2007 10:42:00 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Community Crosstalk: Matthew O'Phinney & Scott Johnson on Dynamic Function/Method Calls]]></title>
      <guid>http://www.phpdeveloper.org/news/5681</guid>
      <link>http://www.phpdeveloper.org/news/5681</link>
      <description><![CDATA[<p>
In two related posts from <i>Scott Johnson</i> and <i>Matthew Weir O'Phinney</i>, there's a question about metaprogramming in PHP, specifically between the use of call_user_func, call_user_func_array, and variable function calls (as asked <a href="http://fuzzyblog.com/archives/2006/06/22/php-advice-requested-variable-functions-versus-call_user_func-and-call_user_func_array/">by Scott</a>).
</p>
<blockquote>
One of the characteristics of meta programming is lots and lots of dynamicism everywhere. So here's my php question: Is there a real difference between <a href="http://us3.php.net/manual/en/function.call-user-func.php">call_user_func</a> versus <a href="http://us3.php.net/manual/en/function.call-user-func-array.php">call_user_func_array</a> and the <a href="http://us3.php.net/manual/en/functions.variable-functions.php">variable function</a> syntax i.e. $function_name() ? As best as a quick  experiment shows they seem to function the same although I did a quick hack / quick doc check as opposed to really drilling into it.  Any efficiency benefits in doing  it one way or another?
</blockquote>
<p>
<i>Matthew</i> <a href="http://weierophinney.net/matthew/archives/121-Benchmarking-dynamic-functionmethod-calls.html">replies on his blog</a> by running some benchmarks (and wondering why <i>Scott</i> didn't run his own).
</p>
<blockquote>
<p>
Back to benchmarking. Scott asks, "Is there a real difference between call_user_func versus call_user_func_array and the variable function syntax i.e. $function_name()?"
</p>
<p>
The short answer: absolutely. The long answer? <a href="http://weierophinney.net/matthew/archives/121-Benchmarking-dynamic-functionmethod-calls.html#extended">Read on</a>. 
</p>
</blockquote>
<p>
He <a href="http://weierophinney.net/matthew/archives/121-Benchmarking-dynamic-functionmethod-calls.html#extended">details what the differences are</a> in the functionality (how they're used and all) as well as examples of their usage. He whips up a test class and function to go through different benchmarks, testing response times with the microtime functionality of PHP. He results aren't too surprising, but you'll have to <a href="http://weierophinney.net/matthew/archives/121-Benchmarking-dynamic-functionmethod-calls.html#extended">check out his post</a> to get the full details.
</p>]]></description>
      <pubDate>Mon, 26 Jun 2006 06:14:51 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Matt Kalinowski's Blog: Determine Browser Speed with PHP]]></title>
      <guid>http://www.phpdeveloper.org/news/5477</guid>
      <link>http://www.phpdeveloper.org/news/5477</link>
      <description><![CDATA[<p>
On <i>Matt Kalinowski</i>'s blog, there's a <a href="http://shortkid422.com/2006/05/31/determine-browser-speed-with-php/">quick post</a> with some code to help you test just how fast your user's browser speed is as they hit your site.
</p>
<quote>
<i>
So, you have a site that offers both an enhanced and standard style page. However, you realize that not every web user is going to know if they would be best suited for either version. Therefor, this speed test will allow you to determine their speed. This could also be used in other situations as well, but the one stated above is the one I found most appropriate.
</i>
</quote>
<p>
Basically, <a href="http://shortkid422.com/2006/05/31/determine-browser-speed-with-php/">the script</a> works with the microtime functionality in PHP to do some speed tests for the amount of data given divided by how long it takes that data to get out to the user.
</p>]]></description>
      <pubDate>Wed, 31 May 2006 05:52:52 -0500</pubDate>
    </item>
  </channel>
</rss>
