Not sure why this is but in Apache 2.2, I had "NameVirtualHost *:80" in the httpd-vhosts.conf file. This was seemingly randomly making the virtualhosts point through to the htdocs root. Updating this to "NameVirtualHost localhost:80" has fixed the issue.
Not sure what the cause is, just glad to see the back of it.
Retweet this button on every post blogger
Showing posts with label Apache. Show all posts
Showing posts with label Apache. Show all posts
Wednesday, 30 December 2009
Monday, 21 December 2009
Restart Apache Server In Mac OSX
Depending on the location of the apachectl file the following syntax will restart Apache from within terminal:
sudo /Applications/MAMP/Library/bin/apachectl restart Retweet this button on every post blogger
sudo /Applications/MAMP/Library/bin/apachectl restart Retweet this button on every post blogger
Monday, 7 December 2009
Getting Apache RewriteRule to work
No intro or background, to get the RewriteRule to work in htaccess you need to activate it. This is specifically for Apache and not ISAPI rewrite on IIS.
- Open httpd.conf
- Look for MULTIPLE occurances of AllowOverride None
- Change to AllowOverride All
- Un comment this line #LoadModule rewrite_module modules/mod_rewrite.so
- Save & restart the apache server
- Apache recommend not using htaccess for peformance reasons. There are other methods for nice urls.
- This is a Dev environment. I've not check out if the above has any security issues, for live servers.
Friday, 21 August 2009
Disable Directory Browsing in Apache
Open the config file and change this line:
- Options Indexes FollowSymLinks
- Options FollowSymLinks
Subscribe to:
Posts (Atom)