On Jul 20, 2006, at 3:01 PM, Michael Peters wrote:



Michael Petnuch wrote:

On Jul 20, 2006, at 2:52 PM, Michael Peters wrote:


I tried adding this line inside the '/' location and just inside the
virtual host declaration.  Both didn't work.

RewriteRule /(.*) /app/$1


Checking the logs that seems to map to the right place... but it is
expecting a real file instead of using Dispatch, i.e. it is giving me a
'File does not exist' error in the apache error log.

Set your RewriteLogLevel to 3 and your then tail your RewriteLog to see why
things aren't getting matched.


I had already set the debug level to 9 (from the Dispatch docs) to see what was going on. As I said the rewrite logs seem to indicate that the mapping is occurring as expected but it is trying to load a real file.

Here is an example. I wrote into my browser: http://www.petnuch.com/ main/main which I wanted to get mapped to app/main/main. Here is the info:

Rewrite log snip:
XXX.XXX.XXX.XXX - - [20/Jul/2006:15:11:55 --0400] [www.petnuch.com/ sid#80bde28][rid#842eeb0/initial] (2) init rewrite engine with requested uri /main/main XXX.XXX.XXX.XXX - - [20/Jul/2006:15:11:55 --0400] [www.petnuch.com/ sid#80bde28][rid#842eeb0/initial] (3) applying pattern '/(.*)' to uri '/main/main' XXX.XXX.XXX.XXX - - [20/Jul/2006:15:11:55 --0400] [www.petnuch.com/ sid#80bde28][rid#842eeb0/initial] (2) rewrite /main/main -> /app/main/ main XXX.XXX.XXX.XXX - - [20/Jul/2006:15:11:55 --0400] [www.petnuch.com/ sid#80bde28][rid#842eeb0/initial] (2) local path result: /app/main/main XXX.XXX.XXX.XXX - - [20/Jul/2006:15:11:55 --0400] [www.petnuch.com/ sid#80bde28][rid#842eeb0/initial] (2) prefixed with document_root to / var/www/petnuch.com/app/main/main XXX.XXX.XXX.XXX - - [20/Jul/2006:15:11:55 --0400] [www.petnuch.com/ sid#80bde28][rid#842eeb0/initial] (1) go-ahead with /var/www/ petnuch.com/app/main/main [OK]

Error log snip:
[Thu Jul 20 15:11:56 2006] [error] [client XXX.XXX.XXX.XXX] File does not exist: /var/www/petnuch.com/app

Why is it requiring app be a "real" file when I have a Location directive for '/app'? Now that I think about it this is more an apache issue so I apologize for posting it here. But I still appreciate the help.


--
Michael Peters
Developer
Plus Three, LP


Attachment: smime.p7s
Description: S/MIME cryptographic signature

Reply via email to