httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dwayne Tharpe <dtha...@unc.edu>
Subject Re: [users@httpd] .htaccess error URGENT
Date Thu, 29 Jun 2006 20:58:07 GMT
I tried that but no luck.  I thought there would be something that I 
could use to just tell it ignore that it's a subdirectory name and go 
ahead with the re-write.

Dwayne

Andy Buckley wrote:
> Joshua Slive wrote:
>> On 6/29/06, Dwayne Tharpe <dtharpe@unc.edu> wrote:
>>> Hi all,
>>>
>>> I'm new to this and have never used mod-rewrite before or used regular
>>> expressions.
>>>
>>> We have a need to mod_rewrite a link.  Below is what I'm using in a
>>> .htaccess file:
>>>
>>> RewriteEngine on
>>> Options FollowSymLinks
>>> RewriteRule ^overview$ /guide/index.cfm?item=Chapter&Chapter_ID=C342 
>>> [L]
>>>
>>> The problem is that "overview" is the name of a subdirectory under
>>> guide, so I get an error (403 I think)
>>> when it tries to rewrite. I can't rename the subdirectory and the users
>>> are demanding that they be able to use just the word "overview" as a
>>> hyperlink.
>>>
>>> Any suggestions? And I'm under a major time constraint :(
>>
>> What does the error log say?  What does the RewriteLog say?
>>
>> The easist way to do this would be to put the RewriteRule in the main
>> server config rather than in .htaccess.  Then you can simply use
>> RewriteRule ^/guide/overview$ 
>> /guide/index.cfm?item=Chapter&Chapter_ID=C342 [L]
>
> Otherwise, as you're using a .htaccess file, you probably need to add a
> "RewriteBase /guide" statement. Otherwise you get into a sort of
> chicken/egg scenario about the order of resolving URLs to bits of the
> filesystem: see the bit at the top of the mod-rewrite docs for more info.
>
> Andy
>
>
>
> ---------------------------------------------------------------------
> 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

-- 
Dwayne Tharpe
Applications Analyst Programmer II
Highway Safety Research Center @ UNC
919.843.4963





---------------------------------------------------------------------
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