Mac OS X Leopard: Web Sharing Troubles: “Forbidden”

M

If you’ve installed Mac OS X Leopard 10.5 already and you use the built in apache server “Web Sharing” you will need to follow these steps before your web server works again. If you’ve tried to visit a page on your local server, you will be greeted by this message:

Forbidden (403)

You don't have permission to access /~danielerrante/ezslide/ on this server.

Leopard fails to copy the settings from apache in Tiger to apache2 in Leopard. Therefore, you will need to follow these simple steps to get your server up again.

If you can vaguely remember creating a configuration file when you first set up Tiger called yourusername.conf, you will need to do that in apache2’s /etc/apache2/users/ folder and add the following to that file:

<Directory "/Users/danielerrante/Sites/">
Options Indexes MultiViews
AllowOverride All
Order allow,deny
Allow from all
</Directory>

Replace danielerrante with your username. Or, you can do all that by copying and pasting one line in terminal:

sudo cp /private/etc/httpd/users/* /private/etc/apache2/users/

Next, you will need to /etc/apache2/httpd.conf and enable PHP5. To do this, navigate to this line:

#LoadModule php5_module libexec/apache2/libphp5.so

Uncomment that line by removing the pound sign.

Last step: Restart your web server by going to the system preferences, uncheck web sharing, then check it again so it restarts.

You’re done!

Source: http://discussions.apple.com/thread.jspa?threadID=1187457&tstart=15

About the author

Daniel Errante

Add Comment

By Daniel Errante

Daniel Errante

Get in touch

Quickly communicate covalent niche markets for maintainable sources. Collaboratively harness resource sucking experiences whereas cost effective meta-services.

Close Bitnami banner
Bitnami