Víctor Yoalli

How to set a Default PHP version in Ubuntu

Sometimes you need to have several PHP versions on your server or machine. This command will prompt you to select the version you want. That's it.

Sometimes you need to have several PHP versions on your server or machine.

bash
sudo update-alternatives --config php

This command will prompt you to select the version you want.

bash
sudo update-alternatives --set /usr/bin/php7.4

That's it.

ESCRITOS DE VÍCTOR