I’m under the understanding that it is a good practice to have apache2
installed for RoR, and so I’ve used macports on OSX to install that,
and then I stopped the existing server and restarted the apache2
instance using /opt/local/apache/bin/apachectl. So far, so good. I
get the welcome screen when I point at localhost. But of course I
don’t want to break other things on the machine, so I need to get
apache2 to handle the existing PHP pages on the machine.
At that point I am blocked. I did a “port install php5”, and it
worked without error, but I don’t see how to tell apache2 to know
about this. I tried
AddType application/x-httpd-php .php
AddHandler php5 .php
and restarted apachectl (without warning), but when I navigate to an
existing page, I just see the PHP code, not the result.
Can anyone offer a pointer to get me going? I realize that I’m saying
an ugly word (“php”) here, but I think it’s acceptable for me to ask
this here, since others may also want to have both RoR and PHP pages
deployed on a single machine.