MacOS 12.1 After successfully installing php 8.1 with homebrew (along with apache/mySQL and phpmyadmin) I am trying unsuccessfully to install/link php 7.4. After following instructions to install, unlink, link, php -v returns 7.4 but phpinfo() shows 8.1. What am I doing wrong?
Question posted in PHP Versions
You can find a list of all versions here.
You can find a list of all versions here.
2
Answers
It looks as if I never successfully killed the included MacOS Apache. I uninstalled home-brew and the server was still running (with PHP8.1!). Not sure what went wrong.
Strange enough, using a full name such as "shivammathur/php/[email protected]" for the link command is what worked for me.
Eg:
Also, don’t forget to close your terminal completely and reopen it before checking the version with php -v.