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

Changeblog:
How to install PHP 5.3 and 5.2 together on Ubuntu 12.04
Aug 06, 2012 @ 16:18:57

On the Changeblog there's a recent post showing you how to get both PHP 5.2 and PHP 5.3 installed on the same machine for your development or testing needs (they target it at Durpal users, but it applies for any PHP app).

Although Drupals 7+ run smoothly on PHP 5.3, Drupal 6 still feels much better with PHP 5.2. Even though D6 core is compatible with PHP 5.3 for quite some time now, a lot of contributes modules still get nasty hiccup when asked to run on the newer version. Therefore developing for both D7 and D6 at the same time becomes much less painful when running both versions of PHP in parallel.

They help you get things compiled from source with the command line input you'll need to get it up and working. Also included is a handy section about possible errors you could get during the configure as well as the packages you might need to install to fix them. Also included are the updates you'll need to make to your configuration files to get things up and running.

tagged: multiple version simultaneous install ubuntu

Link:

Hakre's Blog:
Iterating over Multiple Iterators at Once
Apr 16, 2012 @ 17:09:44

In a recent post to his blog Hakre looks at iterating over iterators (multiples all at once) using either the Append Iterator or the MultipleIterator.

PHP’s SPL has two build-in Iterators that deal with multiple iterators at once: AppendIterator and MultipleIterator. In this posting I’ll cover both a bit.

He gives some sample code for each - showing how to use the AppendIterator to combine multiple iterators into one set and using the MultipleIterator to attach (not append/merge into one set) multiple iterator objects to a single, iteratable object. He als mentions a "lost" iterator, the DualIterator that never made it out of a SVN repository and into the main codebase.

tagged: iterating multiple simultaneous appenditerator multipleiterator tutorial

Link:

Stefan Esser's Blog:
Xdebug 2.0.3 - Stealth Patch
Aug 04, 2008 @ 13:43:52

Stefan Esser has released a patch, pulled originally from the Suhosin project's functionality, that allows you to use a bit of stealth for run the Zend Debugger and XDebug at the same time.

Those asking usually can understand why running two debuggers at the same time will lead to problems, but they don't understand why problems should arise when only one is used at a time. They want to be able to load Zend Debugger and Xdebug with the same php.ini without the need to restart the whole server just to change the debugger.

You can grab the patch from his site and install it like normal. With the patch, your PHP install will handle the rest behind the scenes.

tagged: zenddebugger xdebug patch stealth simultaneous download

Link:

Stoyan Stefanov's Blog:
Simultaneous HTTP requests in PHP with cURL
Feb 19, 2008 @ 15:34:00

On his blog today, Stoyan Stefanov has a howto posted on a trick he figured out to get a PHP script to grab data from multiple resources at one time - with cURL.

The basic idea of a Web 2.0-style "mashup" is that you consume data from several services, often from different providers and combine them in interesting ways. This means you often need to do more than one HTTP request to a service or services. [...] Using the curl_multi* family of cURL functions you can make those requests simultaneously. This way your app is as slow as the slowest request, as opposed to the sum of all requests. And that's something.

He includes example code that loops through a given array of resources and executes the fetch, brining the results back into a result array. To illustrate, he also includes two types of examples of fetching content - one for GET and another for POST.

tagged: curl simultaneous http request tutorial get post

Link:

Nexen.net:
PHP 4 and PHP 5 are in a boat : from will to reality
Oct 03, 2007 @ 17:04:00

On Nexen.net today, Damien Seguy presents some numbers on something that there's not a lot of research done on - the number of servers running multiple PHP versions.

This subject was hot at the birth of PHP 4 (running PHP 4 and PHP 3, or course), and it is coming back with a vengeance for PHP 5, backed by the immense user base of PHP 4. If PHP 5 is the default installation in 2008, what will happen to all those users? [...] Based on this observation and my earlier experience of cohabitation, I wondered if there was any indicator of multiple PHP installation.

He used the same tracker he implements for his normal monthly stats and ran a modified query to get the numbers of multiple-version servers that are out there. He's graphed some of the results. Based on his results, though, he notes a market for multiple PHP installations but "a pretty small one", noting that you're probably better off making the jump out to PHP5 anyway.

tagged: php4 php5 simultaneous installation graph statistics php4 php5 simultaneous installation graph statistics

Link:

Nexen.net:
PHP 4 and PHP 5 are in a boat : from will to reality
Oct 03, 2007 @ 17:04:00

On Nexen.net today, Damien Seguy presents some numbers on something that there's not a lot of research done on - the number of servers running multiple PHP versions.

This subject was hot at the birth of PHP 4 (running PHP 4 and PHP 3, or course), and it is coming back with a vengeance for PHP 5, backed by the immense user base of PHP 4. If PHP 5 is the default installation in 2008, what will happen to all those users? [...] Based on this observation and my earlier experience of cohabitation, I wondered if there was any indicator of multiple PHP installation.

He used the same tracker he implements for his normal monthly stats and ran a modified query to get the numbers of multiple-version servers that are out there. He's graphed some of the results. Based on his results, though, he notes a market for multiple PHP installations but "a pretty small one", noting that you're probably better off making the jump out to PHP5 anyway.

tagged: php4 php5 simultaneous installation graph statistics php4 php5 simultaneous installation graph statistics

Link:

Gentoo Blog:
Reminder - You *Can* Run PHP4 And PHP5 On The Same Box At The Same Time
Apr 21, 2006 @ 20:06:26

Stuart Hebert of the Gentoo blog has posted this new item as a reminder to all of those naysayers out there that didn't think it could be done that PHP4 and PHP5 can live together happily on the same box.

Today has served as a timely reminder to me that not everyone understands that it's perfectly possible to have both PHP4 and PHP5 installed in Apache at the same time. A lot of folks just stop when they learn that you can't load mod_php4 and mod_php5 at the same time into Apache. There's no solution in the excellent PHP Manual that I could spot this afternoon (maybe I've just missed it?), and a lot of folks just don't get any further along than that.

As an illustration of its possiblity, he points to this article from Andreas Korthaus showing how it's done under various different types of installs (Apache/CGI, Aapche/suphp).

tagged: multiple versions same box simultaneous cgi module suphp multiple versions same box simultaneous cgi module suphp

Link:

Gentoo Blog:
Reminder - You *Can* Run PHP4 And PHP5 On The Same Box At The Same Time
Apr 21, 2006 @ 20:06:26

Stuart Hebert of the Gentoo blog has posted this new item as a reminder to all of those naysayers out there that didn't think it could be done that PHP4 and PHP5 can live together happily on the same box.

Today has served as a timely reminder to me that not everyone understands that it's perfectly possible to have both PHP4 and PHP5 installed in Apache at the same time. A lot of folks just stop when they learn that you can't load mod_php4 and mod_php5 at the same time into Apache. There's no solution in the excellent PHP Manual that I could spot this afternoon (maybe I've just missed it?), and a lot of folks just don't get any further along than that.

As an illustration of its possiblity, he points to this article from Andreas Korthaus showing how it's done under various different types of installs (Apache/CGI, Aapche/suphp).

tagged: multiple versions same box simultaneous cgi module suphp multiple versions same box simultaneous cgi module suphp

Link:


Trending Topics: