简单扼要,直接上命令:
rpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm
yum install php70w
每错,就是这么有尿性,接下来用命令看看你的php版本吧:
php -v
PHP 7.0.3 (cli) (built: Feb 4 2016 20:50:17) ( NTS ) Copyright (c) 1997-2016 The PHP Group Zend Engine v3.0.0, Copyright (c) 1998-2016 Zend Technologies
我的天~~啊,看到没有,php 7.0.3 版本,就是这么神奇!
关于php模块的安装:
yum install php70w-模块名
PS:多附上一种安装方式吧(通过 Remi repository 安装):
首先安装 Remi 源:
yum -y install http://rpms.famillecollet.com/enterprise/remi-release-7.rpm
通过 Remi 源安装php 7:
yum –enablerepo=remi -y install php70
查看 php 版本:
php70 -v
PHP 7.0.4 (cli) (built: Mar 2 2016 17:13:39) ( NTS ) Copyright (c) 1997-2016 The PHP Group Zend Engine v3.0.0, Copyright (c) 1998-2016 Zend Technologies