Author Topic: How to use php7.2 in terminal?  (Read 9142 times)

0 Members and 1 Guest are viewing this topic.

Offline
*
How to use php7.2 in terminal?
« on: March 29, 2018, 12:27:16 AM »
I am using the php selector I am able to use php 7.2 by adding it to the .htaccess files and it works but how do I switch in the command line / terminal ?

Offline
***
Re: How to use php7.2 in terminal?
« Reply #1 on: June 08, 2018, 09:09:54 AM »
Using an alias to change the PHP version, you can read more details here :
https://help.dreamhost.com/hc/en-us/articles/214202148-How-do-I-change-the-PHP-version-my-shell-uses-

Just make sure your path to php is correct

Offline
*
Re: How to use php7.2 in terminal?
« Reply #2 on: December 04, 2018, 04:11:44 AM »
/opt/alt/php72/usr/bin/php-cgi -q -c /home/user/public_html/php.ini -f /home/user/public_html/file.php