Mod_Rewrite

This is a discussion on Mod_Rewrite within the Apache Web Server forums, part of the Web Server and Related Forums category; I have the following rewrite rule in my virtual host directive. RewriteRule ^/(.*) http://localhost:8080/VirtualHostBase/http/www.virtualdomain.com:...


Go Back   Usenet Forums > Web Server and Related Forums > Apache Web Server

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 06-27-2006
tstrokes
 
Posts: n/a
Default Mod_Rewrite

I have the following rewrite rule in my virtual host directive.
RewriteRule ^/(.*)
http://localhost:8080/VirtualHostBase/http/www.virtualdomain.com:80/www_virtualdomain_com/VirtualHostRoot/$1
[L,P].
I was wondering how I could exclude one directory from this Rewrite
Rule.
I want every request to be redirected to the zope server except when
they request the directory 'test'.
--tstrokes

  #2 (permalink)  
Old 06-27-2006
Jim Hayter
 
Posts: n/a
Default Re: Mod_Rewrite

tstrokes wrote:
> I have the following rewrite rule in my virtual host directive.
> RewriteRule ^/(.*)
> http://localhost:8080/VirtualHostBase/http/www.virtualdomain.com:80/www_virtualdomain_com/VirtualHostRoot/$1
> [L,P].
> I was wondering how I could exclude one directory from this Rewrite
> Rule.
> I want every request to be redirected to the zope server except when
> they request the directory 'test'.
> --tstrokes
>


Prefix your rewrite rule with rewrite conditions (untested).

RewriteCond %{REQUEST_URI} !^/test$
RewriteCond %{REQUEST_URI} !^/test/(.*)

Jim
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 01:08 PM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0