How to Install PHP 5.4 or PHP 5.5 or PHP 5.6 on Ubuntu 16.04, 14.04 or…
최고관리자
Ubuntu
0
10777
2016.12.16 21:11
Install PHP 5.4
Use the following set of command to add PPA for PHP 5.4 in your Ubuntu system and install PHP 5.4.
$ sudo apt-get install python-software-properties $ sudo add-apt-repository ppa:ondrej/php5-oldstable $ sudo apt-get update $ sudo apt-get install -y php5
Check Installed PHP Version:
# php -v PHP 5.4.35-1+deb.sury.org~precise+1 (cli) (built: Nov 19 2014 19:34:07) Copyright (c) 1997-2014 The PHP Group Zend Engine v2.4.0, Copyright (c) 1998-2014 Zend Technologies
Install PHP 5.5
Use the following set of command to add PPA for PHP 5.5 in your Ubuntu system and install PHP 5.5.
$ sudo apt-get install python-software-properties $ sudo add-apt-repository ppa:ondrej/php $ sudo apt-get update $ sudo apt-get install -y php5.5
Check Installed PHP Version:
# php -v PHP 5.5.19-1+deb.sury.org~precise+1 (cli) (built: Nov 19 2014 19:32:57) Copyright (c) 1997-2014 The PHP Group Zend Engine v2.5.0, Copyright (c) 1998-2014 Zend Technologies with Zend OPcache v7.0.4-dev, Copyright (c) 1999-2014, by Zend Technologies
Install PHP 5.6
Use the following set of command to add PPA for PHP 5.6 in your Ubuntu system and install PHP 5.6.
$ sudo apt-get install python-software-properties $ sudo add-apt-repository ppa:ondrej/php $ sudo apt-get update $ sudo apt-get install -y php5.6
Check Installed PHP Version:
# php -v PHP 5.6.3-1+deb.sury.org~precise+1 (cli) (built: Nov 19 2014 19:34:53) Copyright (c) 1997-2014 The PHP Group Zend Engine v2.6.0, Copyright (c) 1998-2014 Zend Technologies with Zend OPcache v7.0.4-dev, Copyright (c) 1999-2014, by Zend Technologies