I just finished setting up a local site for development wit开发者_如何学Pythonh apache2 on OSX, but what happens is that when i go to my site (cakephp with htaccess and index.php) i get simply a list of the files and folders that i can click, instead of the actual website.
I tried to put an index.html
and the index page loads right. But when i remove it, i get a list of files in the directory.
Any help?
I was missing the line:
WSGIScriptAlias / /path/to/mysite/apache/django.wsgi
I think you have to add type for php files in httpd.conf file:
AddType application/x-httpd-php .php
Remember to restart apache after this. Can you post your .htaccess file?
Additionally, you could simply download and install MAMP on your Mac. It's a pack with Apache+PHP+MySql. You can find it here: http://www.mamp.info/en/index.html but remember to uninstall apache that you already installed (to avoid conflicts).
精彩评论