Skip to content

[Linux]Change PHP Cli Version

just an example, upgrade php cli version to php 7.1, make sure you have sudo right

sudo rm /usr/bin/php
sudo ln -s /opt/plesk/php/7.1/bin/php /usr/bin/php

or

For Ubuntu edit: ~/.profile

For Centos edit: ~/.bash_profile

create alias

alias php='/opt/plesk/php/7.1/bin/php /usr/bin/php'

 

Share

Comments are closed.