PHP version in SSH?


#1

I have my site set to PHP 5.3 in order to use FuelPHP.

I also want to use the command line features of FuelPHP (OIL), so I SSH’d in to the server and attempted to start using OIL. Everything I did failed with an error message, so I started digging… turns out even though my site is set to PHP 5.3, the SSH was running 5.2, which is incompatible with Fuel.

How can I select which version of PHP to use with SSH?

Thanks.


#2

If you specify “php-5.3” on the command line, you will get PHP 5.3.

Alternatively, you can put /usr/local/php53/bin on your $PATH, as that location contains a “php” which is PHP 5.3:


#3

Awesome! That works perfectly. I knew it had to be something simple like that.