How to update PHP to v5.4 or v5.5 on CentOS droplet?

August 15, 2013 9.1k views
Im up droplet with CentOS and LAMP by manual, but php version is little outdated (5.3.3). How I can update it?
10 Answers
What CentOS version are you using? Which article did you follow on installing php?
Cent OS 6, I am using this article:
by Etel Sverdlov
This tutorial explains how to install Apache, how to install MySQL, how to change the root MySQL password, how to install PHP, and how to see what libraries are available. LAMP stack is a group of open source software used to get web servers up and running. The acronym stands for Linux, Apache ( the web server) , MySQL (the database), and PHP (the language). This tutorial is written for Centos.
yum update
yum upgrade
Just run update to see if there is new version, without upgrading.
??? ?? ????????.
@bogdanov, the version you want is not in the main repositories for CentOS.
You either have to find a 3rd party repo that has the version you need, or compile the php yourself.
Thanks to everyone! I hope, soon we will see new manual about this.
Try installing PHP from the EPEL repo:
"I hope, soon we will see new manual about this."

There are reasons why PHP v5.4 and v5.5 are not in the main CentOS repos yet (namely, security). So, unless there's a specific project that you're working on that requires a more recent version of PHP, there's some risk, w/o much incentive, to using the newer versions.

With that said, RPM and Ubuntu LTS are sometimes criticized for being overly cautious and, thus, too slow in adding newer versions of programs to the official repos. In the end, just make sure that when going outside of the main repos, you keep an eye out for any security concerns that you may need to patch or watch out for.

we had the same problem.

found out this page, and it helps me
@mayaachekhalia2526: What version of CentOS are you using?
Have another answer? Share your knowledge.