Home > Apache > Apache – mod_rewrite

Apache – mod_rewrite

  1. Make sure that an .htaccess override is allowed: in your httpd.conf, you should have a section that defines a section for each Directory on your server. Make sure the AllowOverride is set to All for the correct Directory. For security and performance reasons, do not set AllowOverride to All in <Directory />. Instead, look for the <Directory> block that refers to your actual website directory.
  2. Make sure you are editing the correct httpd.conf rather than a user- or site-specific httpd.conf.
  3. For some reason or another, you might have obtained a copy of CakePHP without the needed .htaccess files. This sometimes happens because some operating systems treat files that start with ‘.’ as hidden, and don’t copy them. Make sure your copy of CakePHP is from the downloads section of the site or our SVN repository.
  4. Make sure Apache is loading up mod_rewrite correctly! You should see something like LoadModule rewrite_module libexec/httpd/mod_rewrite.so or (for Apache 1.3) AddModule mod_rewrite.c in your httpd.conf

=============================

LoadModule rewrite_module modules/mod_rewrite.so # check if its loaded
AllowOverride All # by default somtimes none for <Direcotry “your….webserver >

Advertisements
Categories: Apache
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: