Blogger Information
Blog 5
fans 0
comment 0
visits 8360
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
LInux怎么配置php全局变量
志方网络
Original
1339 people have browsed it

你已经安装了php软件 但是php -v 却发现

[root@iZ2ze6izib4uzfy3rzu875Z php720]# php -v
-bash: php: command not found

这是因为你没有配置变量:

步骤1;打开etc的profile

[root@iZ2ze6izib4uzfy3rzu875Z php720]# vim /etc/profile

步骤2 : 配置一下你的PATH ,你的bin在哪就指向哪里

export PATH=$PATH:/usr/local/php720/bin

步骤3 ; 保存退出:并执行:

[root@iZ2ze6izib4uzfy3rzu875Z php720]# source /etc/profile

步骤4 ; 检测:

[root@iZ2ze6izib4uzfy3rzu875Z php720]# php -v
PHP 7.2.0 (cli) (built: Oct 29 2018 21:53:28) ( ZTS )
Copyright (c) 1997-2017 The PHP Group
Zend Engine v3.2.0, Copyright (c) 1998-2017 Zend Technologies


Statement of this Website
The copyright of this blog article belongs to the blogger. Please specify the address when reprinting! If there is any infringement or violation of the law, please contact admin@php.cn Report processing!
All comments Speak rationally on civilized internet, please comply with News Comment Service Agreement
0 comments
Author's latest blog post