Forum Moderators: phranque

Message Too Old, No Replies

RewriteEngine On Problem

         

freemink

11:26 am on Dec 9, 2002 (gmt 0)

10+ Year Member



Hi.

Just been reading about mod_rewrite and ".htaccess"
Thought it would be a good idea if I started to block certain spiders, and maybe stop direct linking to images etc...

Anyways, I get errors as soon as I add the line
RewriteEngine On
to .htaccess file.

Error is: 403
You don't have permission to access / on this server.

I have used .htaccess to redirect to my own 404 page, and to do permanent redirects. So I know that works okay.

Anybosy know why I might get 403 errors just from adding the single line ("RewriteEngine On")?
What is the most simple mod_rewrite rule I could use as test?

Tyhanks,
freemink

msr986

5:54 am on Dec 11, 2002 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Try adding:

'Options FollowSymLinks'

to your .htaccess file before the 'RewriteEngine On'.

If that does not work, your provider may not allow ModRewrite.

freemink

6:40 pm on Dec 13, 2002 (gmt 0)

10+ Year Member



Thank you msr986. That seems to have done the job.
Much appreciated.