It's not rewriting...

New to mod_rewrite? This is a good place to start.

It's not rewriting...

Postby melchior » Sat Jun 19, 2004 9:55 am

Right now I'm just running my own apache server on my computer and I'm trying to protect my scripts using mod_rewrite. I uncommented all the mod_rewrite lines in the apache configuration file and restarted it all. I got no errors doing this, so I assume it compiled fine.

The problem is, I can put a rewrite rule in the httpd.conf file or a .htaccess file but it never rewrites any URLs... For example:

RewriteEngine on
RewriteRule ^/woot$ /beta

I tried that as a test in a .htaccess file and put it in my root C:\htdocs folder. I went to http://localhost/woot but it didn't show anything, gave me a 404. I went to http://localhost/beta and it showed exactly what it was supposed to. I assume it's something I'm doing wrong with my code, but I've followed this sitepoint article to the point pretty much. Any help here would be greatly appreciated...
melchior
 

Return to Beginner's Corner

Who is online

Users browsing this forum: No registered users and 123 guests

cron