To enable .htaccess files in Mac OS X Snow Leopard:
1. Open terminal. Go to
cd /etc/Apache2
2. Then edit httpd.conf by typing:
sudo vi httpd.conf
3. Search for 'AllowOverride' by typing
/AllowOverride (+ return)
4. Change the line to:
AllowOverride All
(by using 'i' to insert and 'esc' to finish inserting text)
5. Search again for 'AllowOverride' by typing
/AllowOverride (+ return)
6. Change to:
AllowOverride All
7. Repeat these steps until all instances of AllowOverride are set to 'All'
8. Then save the file by pressing SHIFT+ZZ.
9. Then you need to edit your own website's file. CD to 'users' by
cd users
10. Then look for your conf file by typing:
ls
11. My file is called mark.conf, so I edit it by typing:
sudo vi mark.conf
12. Again, make sure the respective line reads:
AllowOverride All
13. Restart Apache by disabling then re-enabling 'Web Sharing' in System Preferences.
No comments:
Post a Comment