View Single Post

  #1 (permalink)  
Old 07-22-2007
\Crash\ Dummy
 
Posts: n/a
Default Cannot get basic RewriteRule to work!

I am brand new to Apache, so be gentle.

I am trying to redirect clients to a different directory using RewriteRule in a
..htaccess file in the root directory. I have been doing it successfully using
DirectoryIndex, but when I try to replace

DirectoryIndex /restricted

with

RewriteEngine on
RewriteRule ^/$ /restricted

it doesn't work. It is as close to a "Hello, World!" operation for RewriteRule
as you can get. What am I missing?

I am using Apache 2.2.4 on W2K Pro. The mod_rewrite module is loaded.
--
Crash