Any comments on upgrading PHP4 to PHP5, on Fedora/Apache2?
Client says their site is all custom built and the programmer wants to make the switch. I'd like to stick within the RPM system, but be able to switch back to 4 quickly as he finds things that break (if any).
It seems to me that RPM installs of both PHP4 and PHP5 should go pretty cleanly. My only real concern would be making sure to backup the httpd.conf in case the RPM install trys to replace it. If they'll go into different directories (not sure if this is possible-- don't use RPM), you can even have them both installed, and switch between them within the httpd.conf.
There's also a howto on setting up PHP4 & 5 side by side in O'Reilly's "Upgrading to PHP 5" book, or a short answer on google groups: http://tinyurl.com/ce8tp . A lot of hosting companies are offering both versions through something like this.
On a related note: PHP5 is a *huge* improvement over PHP4. try/catch, simplexml, and generic getter/setters will make you want to never look back at PHP4. Critics say its becoming more like Java's other little brother (with derisive sneers), but I know I'd never go back. Of course once I get better at Ruby, I may not be going back to PHP at all... :)
HTH, Aaron
On Tuesday 31 May 2005 05:33 pm, Aaron Spiegel wrote:
It seems to me that RPM installs of both PHP4 and PHP5 should go pretty cleanly. My only real concern would be making sure to backup the httpd.conf in case the RPM install trys to replace it.
Unlike portage, I've never had a problem with RPM overwriting a customised config file. It overwrites the files it should, and leaves alone the files that it should leave alone. It will make backups of files, but usually you never need them.
There's also a howto on setting up PHP4 & 5 side by side in O'Reilly's "Upgrading to PHP 5" book....
Ah. Sounds like I need to order the book.
On a related note: PHP5 is a *huge* improvement over PHP4.
Fortunately, I don't have to worry about the actual code.
Of course once I get better at Ruby, I may not be going back to PHP at all... :)
Except that PHP will be out there, all over the place, and you'll either have to work with it or be prepared to convert it all to Ruby.
"Upgrading to PHP 5" book....
Ah. Sounds like I need to order the book.
Its a good book for developers, but if you're just looking to install it and be done, I can probably email you an excerpt. I think 1 page is legal, so long as I don't charge you. :)
Of course once I get better at Ruby, I may not be going back to PHP at all... :)
Except that PHP will be out there, all over the place, and you'll either have to work with it or be prepared to convert it all to Ruby.
That's why I'm lucky to be a [Sys|SAN ]admin for real, and a developer only for pretend. I can usually rewrite my own code. In seriousness though, PHP5 is a cool language, handles threads, and is still faster than Ruby, so I'll likely be keeping my skills sharp on both.