I'm running macOS 10.15 (Catalina) and have installed the latest Apache (2.4.43) using
brew, basically following these steps.
Seems to be working fine, but now I want to enable PHP 7 in Apache as well.
I have the default PHP that comes with macOS Catalina (
php -v says 7.3.11) however Apache's module dir (at least the latest Apache I installed with Home Brew) does not seem to contain any php modules.
I'm quite unsure what
LoadModule line I have to add in
httpd.conf in order to get PHP 7 working in my Apache server. And how or where I should get a PHP 7 .so module file if necessary.
When searching around I find all sorts of different approaches, including installing custom versions of PHP but I'm somewhat reluctant of the risk of messing up my current installation.
Is there an easy, and more importantly: reliable way of enabling PHP 7 in httpd 2.4?