The Apache web server built in to OS X can support virtual hosts (basically more than one web server on one machine; read all about it on Apache's Virtual Host information page).
Over on this MacNN forum, however, there was a discussion on difficulties getting SSI (server side includes) to work on virtual hosts.
In a nutshell, you need to add a new section to the apache.conf file. Read on to see the exact required steps.
The below solution is courtesy of "InterfaceGuy" (Lucas from InterfaceLift.com) on the MacNN forums; he figured out the required edits. To do this, login as root, and edit the /Library/Web Server/Configuration/apache.conf file and make the following changes:
Add the following statement anywhere you like. However, if you place it just above the 'VirtualHost' area of the file, it might be easier to associate with what it does:
Over on this MacNN forum, however, there was a discussion on difficulties getting SSI (server side includes) to work on virtual hosts.
In a nutshell, you need to add a new section to the apache.conf file. Read on to see the exact required steps.
The below solution is courtesy of "InterfaceGuy" (Lucas from InterfaceLift.com) on the MacNN forums; he figured out the required edits. To do this, login as root, and edit the /Library/Web Server/Configuration/apache.conf file and make the following changes:
Add the following statement anywhere you like. However, if you place it just above the 'VirtualHost' area of the file, it might be easier to associate with what it does:
<Directory "/Library/WebServer/InsertDirectoryName">Also, there are two other lines that need to be uncommented in the apache.conf file. These are at the bottom of the file. This is required. It is the only way it knows what to do with a .shtml file. Uncomment the lines:
Options Indexes FollowSymLinks MultiViews ExecCGI +Includes
AllowOverride None
Order allow,deny
Allow from all
</Directory>
AddType text/html .shtmlYou can also uncomment the following line if you want to be able to execute CGIs outside of the cgi-bin directory:
AddHandler server-parsed .shtml
AddHandler cgi-script .cgi
•
[11,437 views]

