Here are the steps on how to do it:
- Be a root user and update the system first. Type:
- Add this repository that will update our php. If you want it to be the latest php version available use this:
- If you want the latest stable php version, use this:
- Now lets update our system again. Type these:
- I noticed that after upgrading the system. My php version is still the same. I also noticed that after upgrading the system "The following package will be as like it was.." which means that our update didn't really take effect. To fix this, we have to do one more command for the system to recognize our installation by:
sudo apt-get update sudo apt-get upgrade
sudo add-apt-repository ppa:ondrej/php5
sudo add-apt-repository ppa:ondrej/php5-oldstable
sudo apt-get update sudo apt-get upgrade
sudo apt-get dist-upgrade
After that, type "php -v" and you should see our application to be updated to our preferred php version.
Reference:
Ask Ubuntu Tutorial
No comments:
Post a Comment