Re: Re: Curious inability to mod_rewrite absolute paths

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Jan 01, 2014 at 09:55:48PM -0500, Borden Rhodes wrote:
> I notice in the log that httpd passes the requests for the first two images 
> through RewriteRule in the .htaccess file. However, the call to fetch 
> /images/bowler.jpeg *doesn't* go through the RewriteRule, but instead (line 50 
> in the log) goes straight through protocol.c and, predictably, fails. This 
> raises three questions:
> 
> 1) Why is the absolute path *not* being passed through a rewrite rule but the 
> other two requests are?

Because the absolute path does not go anywhere near the "dummy"
directory which is where your .htaccess file is, so the .htaccess file
never gets read for that request.

> 2) Can I change this behaviour from an .htaccess file?
> 3) If so, how?

Put your .htaccess file somewhere that it will actually be read for the
requests which you want it to affect.

BTW, you don't need mod_rewrite for this sort of redirection. mod_alias
would do just as well and be more lightweight and less confusing. Your
choice, however.

All the best,

Pete
-- 
Openstrike - improving business through open source
http://www.openstrike.co.uk/ or call 01722 770036 / 07092 020107

Attachment: pgpqaKnvHCn_7.pgp
Description: PGP signature


[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux