Ok, I had some problems with aws or something like that I cannot get mod_rewrite to work.
Just for testing, I did the following:
1 uses the aws console to deploy a new 64-bit ami instance from the wizard
2 yum installed apache
3 edited /etc/httpd/conf/httpd.conf: so that
<Directory /> Options FollowSymLinks AllowOverride None </Directory>
looks like
<Directory /> Options FollowSymLinks AllowOverride All </Directory>
4 made sure that
LoadModule rewrite_module modules/mod_rewrite.so
is in the file and uncommented.
5 restarted apache:
sudo /sbin/service httpd restart
6 created two new files:
/var/www/html/test1.html
contains:
this is test1! /var/www/html/test2.html
contains:
this is test2!
7 created file:
/var/www/html/.htaccess
contains (IN TOTAL):
RewriteEngine on RewriteRule ^test1\.html$ test2.html [L]
8 went to:
http:
I get "this is test1!"
I am doing something wrong here, but for the life of me I have no idea what. Any help is much appreciated ...
EDIT: I added meaningless characters / numbers to the top of my .htaccess file and restarted apache (not 100% sure it was necessary, but what the hey ...) and nothing happened. In other words, I expected that switching to url [aws server] /test1.html would lead to some error, but it is not. I suspect apache is not even reading the .htaccess file.
EDIT: I added the following to the httpd.conf file:
RewriteLog "/tmp/rewrite.log" RewriteLogLevel 9
The file is created when I restart apache, but nothing happens there when I go to any page that I installed. I cannot do something very, very basic here, but I'm not sure that ...