httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Chad Day" <c...@atpco.com>
Subject [users@httpd] RE: users Digest 3 Dec 2002 21:00:19 -0000 Issue 619
Date Tue, 03 Dec 2002 21:26:39 GMT
Thanks for the help, it's definetly using the rewrite rule now.

Unfortunately, it's doing it for everything in the domain, even
calendar.domain.com, not just 404 files.

It triggers the rule and just keeps looping back to view.php .. I tried
messing with the rule a bit:

(one of the things I tried)
RewriteLog /path/to/my/log
RewriteEngine on
RewriteCond %{REQUEST_URI}/?$ !-f
#RewriteCond %{REQUEST_URI} ^/([^/]+)/?$
RewriteRule (/.*) http://calendar.penguinleagues.com/view.php?ID=$1 [R,L]

but I can't seem to get it to go .. anyone else?  Thanks for the help!

Chad

On Tue, 3 Dec 2002, Chad Day wrote:
> RewriteEngine on
> RewriteCond %{REQUEST_URI} ^/([^/]+)/?$
> RewriteCond /usr/local/www/sites/domain.com/htdocs/calendar/$1 !-d [NC]
> RewriteRule /.* http://calendar.domain.com/view.php?ID=$1 [R,L]
> RewriteEngine Off

Hmmm... You're the second person I've seen using RewriteEngine On ...
RewriteEngine off.  Where are people getting that idea?  The RewriteEngine
off is overridding the rewriteEngine On and making apache ignore all the
rewriterules.  Get rid of it.

Also, if you want there to be anything in the $1, you'll need to replace
"/.*" with "/(.*)".

Finally, if you want something in the rewrite log file (good idea!),
you'll want a RewriteLog and RewriteLogLevel directive.

Joshua.


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message