fbpx

How to solve Php version control magento 2 issue

How to solve Php version control Magento 2 issue?

PHP version is a very common issue after upgrade of Magento 2 you change in Cpanel but does not work on CLI command line SSH but when you check the version PHP on the browser it shows you the right PHP version lets see very quickly how to change CLI PHP version quickly

go to Your website root out the site of Public_html there you will find or create a file with name .bashrc and inside this file put this code and control your version change php72 to your desired PHP version

# .bashrc

# Source global definitions
if [ -f /etc/bashrc ]; then
. /etc/bashrc
fi

# User-specific aliases and functions
alias composer=”/usr/local/php72/bin/php-cli /home/allholde/composer.phar”
alias php=”/usr/local/php72/bin/php-cli”

 

hope it helps you while upgrading your Magento store from Magento 2.2.x to 2.3.x

Leave a Reply

Your email address will not be published. Required fields are marked *