About the Author

Chris Shiflett

Hi, I'm Chris, a web developer and a founding member of Analog. I live and work in Brooklyn, NY.


PHP 5's Adoption

There seems to be a growing amount of interest within the PHP community about the slow rate of PHP 5's adoption. Call me crazy, but I tend to think of this as a testament of PHP's success, because it might mean:

  • PHP 4 suits many people's needs, so there's no pressing reason for them to upgrade (think about Apache 1.3).
  • PHP is being used in environments where upgrading is a very controlled process (Yahoo, for example).

I also think PHP 5 will reach a tipping point (check out the book) eventually, so the early rate of adoption isn't necessarily a forecast of PHP 5's future.

Speaking of PHP 5, Upgrading to PHP 5 is one of my favorite PHP books. Despite being a technical reviewer for the book, I find myself referencing it more than any other. Adam does a great job of explaining the new features in PHP 5, and the chapter on OOP is especially good.

About This Post

PHP 5's Adoption was posted on Mon, 03 Oct 2005 at 20:19:56 GMT.

14 Comments

1. Adam Trachtenberg's GravatarAdam Trachtenberg said:

Thanks! Reviews are high, sales are low. I am blaming the slow adoption rate of PHP 5. :)

Tue, 04 Oct 2005 at 00:19:15 GMT Link


2. Bill Humphries's GravatarBill Humphries said:

Hosting providers are reluctant to upgrade as well. I've asked mine and was told, no plans to evaluate or upgrade, I'm welcome to run PHP5 as a CGI.

TextDrive's the only hosting provider I know of offering PHP5.

When the hosting companies begin to switch, then we'll see the rates go up.

Tue, 04 Oct 2005 at 07:25:31 GMT Link


3. GrumpySimon's GravatarGrumpySimon said:

I think a lot of it is also because it "breaks" the mysql_* functions.

First, I know that getting php5 running with the mysql_* functions instead of/as well as mysqli_* tends to confuse a lot of people. I've seen a lot of people just give up, and stick with 4.

Second, 99% of the tutorials and "learn php in 12 hours, you idiot"-style books all use mysql_* examples. Again, this just confuses people - I forget how many times I've seen people on forums freaking out over the "call to undefined function mysql_connect" error.

Third, who wants to change over pages of mysql_* functions when it still works? (sure we should all be abstracting database interaction, but how many people do?).

Fourth, it's MUCH harder to upgrade your database than your scripting language. If you're still on MySQL 4.0 or 3.2 (and many people are), then why bother?

--Simon

Tue, 04 Oct 2005 at 09:30:38 GMT Link


4. Andrzey's GravatarAndrzey said:

For me, there is one reason. There is no free and working acceleration for PHP4. E-accelerator it's not good enough.

Tue, 04 Oct 2005 at 15:06:16 GMT Link


5. preinheimer's Gravatarpreinheimer said:

APC is fast and free: http://pecl.php.net/package/APC

Tue, 04 Oct 2005 at 16:57:07 GMT Link


6. Jim Plush's GravatarJim Plush said:

I think whats starting to scare people is the talk of PHP6 already when PHP5 has been so slow to be adopted. With that the talk of once again not caring about backwards compatibility.

Tue, 04 Oct 2005 at 18:27:14 GMT Link


7. MonkeyT's GravatarMonkeyT said:

From what I've seen locally (Dallas), many are indeed happy with PHP4's stability and are letting sleeping dogs lie with regards to most existing code. PHP users are a pragmatic bunch, and they won't break something that works just to say it's new and shiny. But at the same time, projects that are in the planning stages and systems that are being upgraded/rewritten are mostly being aimed at PHP5. Most of those I know who are mapping out their future plans are pushing towards PHP5 very hard. The main difference seems to be between those who rely on open source projects and those who roll their own code. For the most part, few who write fresh code for a living want to stay on PHP4 a minute longer than they have to. Admittedly, most of the devs I know run their own servers as well, which makes the changeover a little simpler.

Tue, 04 Oct 2005 at 18:54:57 GMT Link


8. Ulrich Speidel's GravatarUlrich Speidel said:

There are quite a few (big) providers that offer PHP5 now, but legacy code is making upgrade difficult. My own employer won't upgrade yet for just that reason. That said, I agree that there's a tipping point coming. My own PHP5 book with O'Reilly in Germany (published under my pre-marital name Ulrich Günther) seems to have picked up in sales just recently. There's hope for your excellent book, Adam (I was involved in translating it into German).

Tue, 04 Oct 2005 at 22:09:31 GMT Link


9. Roman's GravatarRoman said:

There is very bad thing with PHP 5! It is very difficult to find hosting company that offers PHP 5 hosting :(

Sat, 10 Dec 2005 at 16:56:14 GMT Link


10. Niko's GravatarNiko said:

It's an old post, but <a href="netfirms.com">Netfirms</a> provides a good php5 hosting

Fri, 11 Aug 2006 at 15:27:14 GMT Link


11. Jon's GravatarJon said:

I still only write code that will work on PHP 4 and PHP 5. I don't want to waste time with servers switching versions and things not working.

I trust ADODB will work on PHP 4, 5 and 6 and not make me rewrite everything.

Tue, 19 Sep 2006 at 10:33:54 GMT Link


12. Mozart's GravatarMozart said:

I think soon the majority of web developers will pass with PHP4 on PHP5

Sat, 23 Sep 2006 at 10:11:58 GMT Link


13. Isaac Menely's GravatarIsaac Menely said:

Hey bro,

I was curious if you could help me. I've got a search engine site that I've customized the crud out of. It worked great with my old hosting package which ran

php4.

When I upgraded to a better hosting account which was

a VirtualServer with Plesk and Virtuozzo for admin panel platforms, it was running php5. And alot of the functionality of my site stopped working.

One is definately the admin.php page. Where a simple login used to work, now it won't set the cookie for the admin session.

And there is some amount of error in the members area

upon trying to login. No cookie to set there, but the user

thats called out in the script upon login winds up at a

blank page where it would look like the variable didn't

get sent to the code in the members main area when

they login.

I'm just not quite getting it. Is there a chunk of code that works for php5 that I can place in this script that will set

a session cookie?

Thanks Chris, happy thanksgiving.

Thu, 23 Nov 2006 at 18:09:55 GMT Link


14. Colin's GravatarColin said:

My host, mediatemple, os now offering a grid server set that i just upgraded to, which offer side-by-side php4 and php5 (configurable) by host and (i believe maybe) folder.

Thats just the tip of the iceburg for (mt)'s hosting plan (gs)

http://www.mediatemple.com/

Wed, 13 Dec 2006 at 09:04:06 GMT Link


Post A Comment

Personal Details and Comment

Style Guide

Line breaks are converted to paragraphs. Also use:

  • <a href="" title="">text</a>1
  • <em>text</em>
  • <blockquote><p>text</p></blockquote>
  • <code>2  <?php  if ($foo) {      $foo = TRUE;  }  ?></code>
  1. Note: <code> can be used inline (e.g. in paragraphs) or in a block as shown. Include whitespace and newlines in blocks.

Please enter Chris (my first name) below. This is a primitive spam prevention technique, and I apologize for the inconvenience.

Preview and Submit

Upcoming Talks

ConFoo

10 - 12 Mar 2010

At Hilton Montréal Bonaventure, Montréal, Canada.

South by Southwest

12 - 16 Mar 2010

At Austin Convention Center, Austin, Texas.

Dutch PHP Conference

10 - 12 Jun 2010

At TBD, Amsterdam, Netherlands.

O'Reilly Open Source Convention

19 - 23 Jul 2010

At Oregon Convention Center, Portland, Oregon.

New Comments

Niall Kelly wrote:

Having tried other methods without success and looked through plenty of bloated documentation, th...

Posted in Git on Snow Leopard
liukang wrote:

I have problem with this example. In my php.ini magic_quotes_gpc is off so i'm using only addsla...

Posted in addslashes() Versus mysql_real_escape_string()
RyanTheGreat wrote:

Well, I'm not Chris, but I will do my best to address the questions raised in the comments by Ian...

Posted in Security Corner: Cross-Site Request Forgeries
Chris Shiflett wrote:

Thanks for the kind words, Simon. I'm glad you liked the tutorial. In case it's helpful, here'...

Posted in Webstock
Chris Shiflett wrote:

Hi Robin, I plan to post something about it, but it's going to be hard to express everything i...

Posted in Webstock

Browse Comments


Work and Books

Analog Essential PHP Security HTTP Developer's Handbook