mod_rewrite 和 mod_userdir 的问题

发布于 2024-12-08 07:22:08 字数 11939 浏览 1 评论 0原文

我正在尝试获取其他人组装的正在运行的网站的本地副本。该网站已部署并正常运行,我正在尝试在我的 public_html 目录下设置开发版本。

该站点使用 mod_rewrite 通过执行各种初始化步骤的网关脚本重定向所有流量。我有一个奇怪的问题,其中包含 .php 扩展名的链接可以工作,但那些没有扩展名的链接会出现以下异常:

警告:未知:无法打开流:未知中没有这样的文件或目录第 0 行致命错误:未知:无法打开所需的 'redirect:/~george/site/.fiona/core/gateway.php' (include_path='.:/usr/share/php:/usr/share/pear') Unknown on line 0

这是 .htaccess 文件的副本(针对我的本地安装进行了编辑)

RewriteEngine On
Options +FollowSymLinks

RewriteBase /~george/site/
RewriteCond %{REQUEST_URI} !.fiona/core/gateway.php
RewriteRule ^\.fiona/([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?$ .fiona/core/gateway.php?group=$1&destination=$2\.php [L,QSA]
RewriteCond %{REQUEST_URI} !.fiona/core/gateway.php
RewriteRule ^([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?$ .fiona/core/gateway.php?group=$1&destination=$2\.php [L,QSA]
RewriteCond %{REQUEST_URI} !.fiona/core/gateway.php
RewriteRule ^([a-zA-Z0-9_\-]+)(\.php)?$ .fiona/core/gateway.php?destination=$1\.php [L,QSA]

这是我在 mod_rewrite 日志

localhost/~george/site/login

127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/login.php -> login.php
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] applying pattern '^\.fiona/([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?$' to uri 'login.php'
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/login.php -> login.php
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?$' to uri 'login.php'
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/login.php -> login.php
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-zA-Z0-9_\-]+)(\.php)?$' to uri 'login.php'
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (4) [perdir /home/george/public_html/site/] RewriteCond: input='/~george/site/login.php' pattern='!.fiona/core/gateway.php' => matched
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (2) [perdir /home/george/public_html/site/] rewrite 'login.php' -> '.fiona/core/gateway.php?destination=login.php'
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) split uri=.fiona/core/gateway.php?destination=login.php -> uri=.fiona/core/gateway.php, args=destination=login.php
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] add per-dir prefix: .fiona/core/gateway.php -> /home/george/public_html/site/.fiona/core/gateway.php
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (2) [perdir /home/george/public_html/site/] trying to replace prefix /home/george/public_html/site/ with /~george/site/
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (5) strip matching prefix: /home/george/public_html/site/.fiona/core/gateway.php -> .fiona/core/gateway.php
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (4) add subst prefix: .fiona/core/gateway.php -> /~george/site/.fiona/core/gateway.php
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (1) [perdir /home/george/public_html/site/] internal redirect with /~george/site/.fiona/core/gateway.php [INTERNAL REDIRECT]
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^\.fiona/([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?$' to uri 'redirect:/~george/site/.fiona/core/gateway.php'
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?$' to uri 'redirect:/~george/site/.fiona/core/gateway.php'
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-zA-Z0-9_\-]+)(\.php)?$' to uri 'redirect:/~george/site/.fiona/core/gateway.php'
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (1) [perdir /home/george/public_html/site/] pass through redirect:/~george/site/.fiona/core/gateway.php

localhost/~george/site/login 中看到的内容。 php

127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/login.php -> login.php
127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^\.fiona/([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?$' to uri 'login.php'
127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/login.php -> login.php
127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?$' to uri 'login.php'
127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/login.php -> login.php
127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-zA-Z0-9_\-]+)(\.php)?$' to uri 'login.php'
127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (4) [perdir /home/george/public_html/site/] RewriteCond: input='/~george/site/login.php' pattern='!.fiona/core/gateway.php' => matched
127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (2) [perdir /home/george/public_html/site/] rewrite 'login.php' -> '.fiona/core/gateway.php?destination=login.php'
127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (3) split uri=.fiona/core/gateway.php?destination=login.php -> uri=.fiona/core/gateway.php, args=destination=login.php
127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (3) [perdir /home/george/public_html/site/] add per-dir prefix: .fiona/core/gateway.php -> /home/george/public_html/site/.fiona/core/gateway.php
127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (2) [perdir /home/george/public_html/site/] trying to replace prefix /home/george/public_html/site/ with /~george/site/
127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (5) strip matching prefix: /home/george/public_html/site/.fiona/core/gateway.php -> .fiona/core/gateway.php
127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (4) add subst prefix: .fiona/core/gateway.php -> /~george/site/.fiona/core/gateway.php
127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (1) [perdir /home/george/public_html/site/] internal redirect with /~george/site/.fiona/core/gateway.php [INTERNAL REDIRECT]
127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224c97b8/initial/redir#1] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/.fiona/core/gateway.php -> .fiona/core/gateway.php
127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224c97b8/initial/redir#1] (3) [perdir /home/george/public_html/site/] applying pattern '^\.fiona/([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?$' to uri '.fiona/core/gateway.php'
127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224c97b8/initial/redir#1] (4) [perdir /home/george/public_html/site/] RewriteCond: input='/~george/site/.fiona/core/gateway.php' pattern='!.fiona/core/gateway.php' => not-matched
127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224c97b8/initial/redir#1] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/.fiona/core/gateway.php -> .fiona/core/gateway.php
127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224c97b8/initial/redir#1] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?$' to uri '.fiona/core/gateway.php'
127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224c97b8/initial/redir#1] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/.fiona/core/gateway.php -> .fiona/core/gateway.php
127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224c97b8/initial/redir#1] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-zA-Z0-9_\-]+)(\.php)?$' to uri '.fiona/core/gateway.php'
127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224c97b8/initial/redir#1] (1) [perdir /home/george/public_html/site/] pass through /home/george/public_html/site/.fiona/core/gateway.php

不带 .php 扩展名的链接似乎成功完成了初始重定向,但是,由于某种原因,它们似乎无法重新路由到绝对路径。

我绝不是 mod_rewrite 方面的专家,因此这里很可能存在其他问题。任何想法都会很棒。

编辑 根据 Marius 的回答,我相信我已经将问题范围缩小到 mod_userdir 与 mod_rewrite 结合使用的问题。将站点移至 /var/www 可以解决该问题。我仍然想让它在我的 public_html 目录中工作。

编辑 Marius 带领我更接近启用站点中的解决方案。事实证明,问题在于没有为用户目录启用 MultiViews(允许 apache 将索引解释为 index.php)。将以下内容添加到我启用的默认站点 (/etc/apache2/sites-enabled/000-default) 解决了 .php 扩展名的问题,但禁用了 mod_rewrite。

<Directory /home/*/public_html>
    Options Indexes FollowSymLinks MultiViews
    AllowOverride None
    Order allow,deny
    allow from all
</Directory> 

我启用的整个网站如下

<VirtualHost *:80>
    ServerAdmin webmaster@localhost

    DocumentRoot /var/www
    <Directory />
        Options FollowSymLinks
        AllowOverride None
    </Directory>
    <Directory /var/www/>
        Options Indexes FollowSymLinks MultiViews
        AllowOverride None
        Order allow,deny
        allow from all
    </Directory>
    <Directory /home/*/public_html>
        Options Indexes FollowSymLinks MultiViews
        AllowOverride all
        Order allow,deny
        allow from all
    </Directory>

    ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
    <Directory "/usr/lib/cgi-bin">
        AllowOverride None
        Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
        Order allow,deny
        Allow from all
    </Directory>

    ErrorLog ${APACHE_LOG_DIR}/error.log

    # Possible values include: debug, info, notice, warn, error, crit,
    # alert, emerg.
    LogLevel warn

    CustomLog ${APACHE_LOG_DIR}/access.log combined

    Alias /doc/ "/usr/share/doc/"
    <Directory "/usr/share/doc/">
        Options Indexes MultiViews FollowSymLinks
        AllowOverride None
        Order deny,allow
        Deny from all
        Allow from 127.0.0.0/255.0.0.0 ::1/128
    </Directory>

</VirtualHost>

I'm trying to get a local copy of a website running that someone else put together. The site is deployed and functional and I'm trying to get a development version set up under my public_html directory.

The site uses mod_rewrite to redirect all traffic through a gateway script that performs various initialization steps. I have a strange problem where links including the .php extention work, but those without die with the following exception:

Warning: Unknown: failed to open stream: No such file or directory in Unknown on line 0 Fatal error: Unknown: Failed opening required 'redirect:/~george/site/.fiona/core/gateway.php' (include_path='.:/usr/share/php:/usr/share/pear') in Unknown on line 0

Here is a copy of the .htaccess file (edited for my local installation)

RewriteEngine On
Options +FollowSymLinks

RewriteBase /~george/site/
RewriteCond %{REQUEST_URI} !.fiona/core/gateway.php
RewriteRule ^\.fiona/([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?$ .fiona/core/gateway.php?group=$1&destination=$2\.php [L,QSA]
RewriteCond %{REQUEST_URI} !.fiona/core/gateway.php
RewriteRule ^([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?$ .fiona/core/gateway.php?group=$1&destination=$2\.php [L,QSA]
RewriteCond %{REQUEST_URI} !.fiona/core/gateway.php
RewriteRule ^([a-zA-Z0-9_\-]+)(\.php)?$ .fiona/core/gateway.php?destination=$1\.php [L,QSA]

Here is what I see in my mod_rewrite logs

localhost/~george/site/login

127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/login.php -> login.php
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] applying pattern '^\.fiona/([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/login.php -> login.php
127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^\.fiona/([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

<Directory /home/*/public_html>
    Options Indexes FollowSymLinks MultiViews
    AllowOverride None
    Order allow,deny
    allow from all
</Directory> 

My entire sites enabled follows

<VirtualHost *:80>
    ServerAdmin webmaster@localhost

    DocumentRoot /var/www
    <Directory />
        Options FollowSymLinks
        AllowOverride None
    </Directory>
    <Directory /var/www/>
        Options Indexes FollowSymLinks MultiViews
        AllowOverride None
        Order allow,deny
        allow from all
    </Directory>
    <Directory /home/*/public_html>
        Options Indexes FollowSymLinks MultiViews
        AllowOverride all
        Order allow,deny
        allow from all
    </Directory>

    ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
    <Directory "/usr/lib/cgi-bin">
        AllowOverride None
        Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
        Order allow,deny
        Allow from all
    </Directory>

    ErrorLog ${APACHE_LOG_DIR}/error.log

    # Possible values include: debug, info, notice, warn, error, crit,
    # alert, emerg.
    LogLevel warn

    CustomLog ${APACHE_LOG_DIR}/access.log combined

    Alias /doc/ "/usr/share/doc/"
    <Directory "/usr/share/doc/">
        Options Indexes MultiViews FollowSymLinks
        AllowOverride None
        Order deny,allow
        Deny from all
        Allow from 127.0.0.0/255.0.0.0 ::1/128
    </Directory>

</VirtualHost>
to uri 'login.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/login.php -> login.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php


The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.


My entire sites enabled follows


 to uri 'login.php'
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/login.php -> login.php
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php


The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.


My entire sites enabled follows


 to uri 'login.php'
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (4) [perdir /home/george/public_html/site/] RewriteCond: input='/~george/site/login.php' pattern='!.fiona/core/gateway.php' => matched
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (2) [perdir /home/george/public_html/site/] rewrite 'login.php' -> '.fiona/core/gateway.php?destination=login.php'
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) split uri=.fiona/core/gateway.php?destination=login.php -> uri=.fiona/core/gateway.php, args=destination=login.php
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] add per-dir prefix: .fiona/core/gateway.php -> /home/george/public_html/site/.fiona/core/gateway.php
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (2) [perdir /home/george/public_html/site/] trying to replace prefix /home/george/public_html/site/ with /~george/site/
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (5) strip matching prefix: /home/george/public_html/site/.fiona/core/gateway.php -> .fiona/core/gateway.php
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (4) add subst prefix: .fiona/core/gateway.php -> /~george/site/.fiona/core/gateway.php
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (1) [perdir /home/george/public_html/site/] internal redirect with /~george/site/.fiona/core/gateway.php [INTERNAL REDIRECT]
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^\.fiona/([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php


The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.


My entire sites enabled follows


 to uri 'redirect:/~george/site/.fiona/core/gateway.php'
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php


The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.


My entire sites enabled follows


 to uri 'redirect:/~george/site/.fiona/core/gateway.php'
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php


The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.


My entire sites enabled follows


 to uri 'redirect:/~george/site/.fiona/core/gateway.php'
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (1) [perdir /home/george/public_html/site/] pass through redirect:/~george/site/.fiona/core/gateway.php

localhost/~george/site/login.php


The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.


My entire sites enabled follows


 to uri 'login.php'
127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/login.php -> login.php
127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.


My entire sites enabled follows


 to uri 'login.php'
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/login.php -> login.php
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php


The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.


My entire sites enabled follows


 to uri 'login.php'
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/login.php -> login.php
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php


The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.


My entire sites enabled follows


 to uri 'login.php'
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (4) [perdir /home/george/public_html/site/] RewriteCond: input='/~george/site/login.php' pattern='!.fiona/core/gateway.php' => matched
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (2) [perdir /home/george/public_html/site/] rewrite 'login.php' -> '.fiona/core/gateway.php?destination=login.php'
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) split uri=.fiona/core/gateway.php?destination=login.php -> uri=.fiona/core/gateway.php, args=destination=login.php
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] add per-dir prefix: .fiona/core/gateway.php -> /home/george/public_html/site/.fiona/core/gateway.php
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (2) [perdir /home/george/public_html/site/] trying to replace prefix /home/george/public_html/site/ with /~george/site/
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (5) strip matching prefix: /home/george/public_html/site/.fiona/core/gateway.php -> .fiona/core/gateway.php
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (4) add subst prefix: .fiona/core/gateway.php -> /~george/site/.fiona/core/gateway.php
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (1) [perdir /home/george/public_html/site/] internal redirect with /~george/site/.fiona/core/gateway.php [INTERNAL REDIRECT]
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^\.fiona/([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php


The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.


My entire sites enabled follows


 to uri 'redirect:/~george/site/.fiona/core/gateway.php'
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php


The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.


My entire sites enabled follows


 to uri 'redirect:/~george/site/.fiona/core/gateway.php'
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php


The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.


My entire sites enabled follows


 to uri 'redirect:/~george/site/.fiona/core/gateway.php'
127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (1) [perdir /home/george/public_html/site/] pass through redirect:/~george/site/.fiona/core/gateway.php

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'login.php' 127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/login.php -> login.php 127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-zA-Z0-9_\-]+)(\.php)?

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'login.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/login.php -> login.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'login.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/login.php -> login.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'login.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (4) [perdir /home/george/public_html/site/] RewriteCond: input='/~george/site/login.php' pattern='!.fiona/core/gateway.php' => matched 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (2) [perdir /home/george/public_html/site/] rewrite 'login.php' -> '.fiona/core/gateway.php?destination=login.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) split uri=.fiona/core/gateway.php?destination=login.php -> uri=.fiona/core/gateway.php, args=destination=login.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] add per-dir prefix: .fiona/core/gateway.php -> /home/george/public_html/site/.fiona/core/gateway.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (2) [perdir /home/george/public_html/site/] trying to replace prefix /home/george/public_html/site/ with /~george/site/ 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (5) strip matching prefix: /home/george/public_html/site/.fiona/core/gateway.php -> .fiona/core/gateway.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (4) add subst prefix: .fiona/core/gateway.php -> /~george/site/.fiona/core/gateway.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (1) [perdir /home/george/public_html/site/] internal redirect with /~george/site/.fiona/core/gateway.php [INTERNAL REDIRECT] 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^\.fiona/([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'redirect:/~george/site/.fiona/core/gateway.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'redirect:/~george/site/.fiona/core/gateway.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'redirect:/~george/site/.fiona/core/gateway.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (1) [perdir /home/george/public_html/site/] pass through redirect:/~george/site/.fiona/core/gateway.php

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'login.php' 127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (4) [perdir /home/george/public_html/site/] RewriteCond: input='/~george/site/login.php' pattern='!.fiona/core/gateway.php' => matched 127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (2) [perdir /home/george/public_html/site/] rewrite 'login.php' -> '.fiona/core/gateway.php?destination=login.php' 127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (3) split uri=.fiona/core/gateway.php?destination=login.php -> uri=.fiona/core/gateway.php, args=destination=login.php 127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (3) [perdir /home/george/public_html/site/] add per-dir prefix: .fiona/core/gateway.php -> /home/george/public_html/site/.fiona/core/gateway.php 127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (2) [perdir /home/george/public_html/site/] trying to replace prefix /home/george/public_html/site/ with /~george/site/ 127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (5) strip matching prefix: /home/george/public_html/site/.fiona/core/gateway.php -> .fiona/core/gateway.php 127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (4) add subst prefix: .fiona/core/gateway.php -> /~george/site/.fiona/core/gateway.php 127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224bf668/initial] (1) [perdir /home/george/public_html/site/] internal redirect with /~george/site/.fiona/core/gateway.php [INTERNAL REDIRECT] 127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224c97b8/initial/redir#1] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/.fiona/core/gateway.php -> .fiona/core/gateway.php 127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224c97b8/initial/redir#1] (3) [perdir /home/george/public_html/site/] applying pattern '^\.fiona/([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'login.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/login.php -> login.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'login.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/login.php -> login.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'login.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (4) [perdir /home/george/public_html/site/] RewriteCond: input='/~george/site/login.php' pattern='!.fiona/core/gateway.php' => matched 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (2) [perdir /home/george/public_html/site/] rewrite 'login.php' -> '.fiona/core/gateway.php?destination=login.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) split uri=.fiona/core/gateway.php?destination=login.php -> uri=.fiona/core/gateway.php, args=destination=login.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] add per-dir prefix: .fiona/core/gateway.php -> /home/george/public_html/site/.fiona/core/gateway.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (2) [perdir /home/george/public_html/site/] trying to replace prefix /home/george/public_html/site/ with /~george/site/ 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (5) strip matching prefix: /home/george/public_html/site/.fiona/core/gateway.php -> .fiona/core/gateway.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (4) add subst prefix: .fiona/core/gateway.php -> /~george/site/.fiona/core/gateway.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (1) [perdir /home/george/public_html/site/] internal redirect with /~george/site/.fiona/core/gateway.php [INTERNAL REDIRECT] 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^\.fiona/([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'redirect:/~george/site/.fiona/core/gateway.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'redirect:/~george/site/.fiona/core/gateway.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'redirect:/~george/site/.fiona/core/gateway.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (1) [perdir /home/george/public_html/site/] pass through redirect:/~george/site/.fiona/core/gateway.php

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri '.fiona/core/gateway.php' 127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224c97b8/initial/redir#1] (4) [perdir /home/george/public_html/site/] RewriteCond: input='/~george/site/.fiona/core/gateway.php' pattern='!.fiona/core/gateway.php' => not-matched 127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224c97b8/initial/redir#1] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/.fiona/core/gateway.php -> .fiona/core/gateway.php 127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224c97b8/initial/redir#1] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'login.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/login.php -> login.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'login.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/login.php -> login.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'login.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (4) [perdir /home/george/public_html/site/] RewriteCond: input='/~george/site/login.php' pattern='!.fiona/core/gateway.php' => matched 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (2) [perdir /home/george/public_html/site/] rewrite 'login.php' -> '.fiona/core/gateway.php?destination=login.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) split uri=.fiona/core/gateway.php?destination=login.php -> uri=.fiona/core/gateway.php, args=destination=login.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] add per-dir prefix: .fiona/core/gateway.php -> /home/george/public_html/site/.fiona/core/gateway.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (2) [perdir /home/george/public_html/site/] trying to replace prefix /home/george/public_html/site/ with /~george/site/ 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (5) strip matching prefix: /home/george/public_html/site/.fiona/core/gateway.php -> .fiona/core/gateway.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (4) add subst prefix: .fiona/core/gateway.php -> /~george/site/.fiona/core/gateway.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (1) [perdir /home/george/public_html/site/] internal redirect with /~george/site/.fiona/core/gateway.php [INTERNAL REDIRECT] 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^\.fiona/([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'redirect:/~george/site/.fiona/core/gateway.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'redirect:/~george/site/.fiona/core/gateway.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'redirect:/~george/site/.fiona/core/gateway.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (1) [perdir /home/george/public_html/site/] pass through redirect:/~george/site/.fiona/core/gateway.php

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri '.fiona/core/gateway.php' 127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224c97b8/initial/redir#1] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/.fiona/core/gateway.php -> .fiona/core/gateway.php 127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224c97b8/initial/redir#1] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-zA-Z0-9_\-]+)(\.php)?

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'login.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/login.php -> login.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'login.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/login.php -> login.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'login.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (4) [perdir /home/george/public_html/site/] RewriteCond: input='/~george/site/login.php' pattern='!.fiona/core/gateway.php' => matched 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (2) [perdir /home/george/public_html/site/] rewrite 'login.php' -> '.fiona/core/gateway.php?destination=login.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) split uri=.fiona/core/gateway.php?destination=login.php -> uri=.fiona/core/gateway.php, args=destination=login.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] add per-dir prefix: .fiona/core/gateway.php -> /home/george/public_html/site/.fiona/core/gateway.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (2) [perdir /home/george/public_html/site/] trying to replace prefix /home/george/public_html/site/ with /~george/site/ 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (5) strip matching prefix: /home/george/public_html/site/.fiona/core/gateway.php -> .fiona/core/gateway.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (4) add subst prefix: .fiona/core/gateway.php -> /~george/site/.fiona/core/gateway.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (1) [perdir /home/george/public_html/site/] internal redirect with /~george/site/.fiona/core/gateway.php [INTERNAL REDIRECT] 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^\.fiona/([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'redirect:/~george/site/.fiona/core/gateway.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'redirect:/~george/site/.fiona/core/gateway.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'redirect:/~george/site/.fiona/core/gateway.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (1) [perdir /home/george/public_html/site/] pass through redirect:/~george/site/.fiona/core/gateway.php

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri '.fiona/core/gateway.php' 127.0.0.1 - - [05/Oct/2011:08:58:18 --0400] [localhost/sid#222fdce8][rid#224c97b8/initial/redir#1] (1) [perdir /home/george/public_html/site/] pass through /home/george/public_html/site/.fiona/core/gateway.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'login.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/login.php -> login.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'login.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] strip per-dir prefix: /home/george/public_html/site/login.php -> login.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'login.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (4) [perdir /home/george/public_html/site/] RewriteCond: input='/~george/site/login.php' pattern='!.fiona/core/gateway.php' => matched 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (2) [perdir /home/george/public_html/site/] rewrite 'login.php' -> '.fiona/core/gateway.php?destination=login.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) split uri=.fiona/core/gateway.php?destination=login.php -> uri=.fiona/core/gateway.php, args=destination=login.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (3) [perdir /home/george/public_html/site/] add per-dir prefix: .fiona/core/gateway.php -> /home/george/public_html/site/.fiona/core/gateway.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (2) [perdir /home/george/public_html/site/] trying to replace prefix /home/george/public_html/site/ with /~george/site/ 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (5) strip matching prefix: /home/george/public_html/site/.fiona/core/gateway.php -> .fiona/core/gateway.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (4) add subst prefix: .fiona/core/gateway.php -> /~george/site/.fiona/core/gateway.php 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#211168d0/subreq] (1) [perdir /home/george/public_html/site/] internal redirect with /~george/site/.fiona/core/gateway.php [INTERNAL REDIRECT] 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^\.fiona/([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'redirect:/~george/site/.fiona/core/gateway.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-z]+)/([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'redirect:/~george/site/.fiona/core/gateway.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (3) [perdir /home/george/public_html/site/] applying pattern '^([a-zA-Z0-9_\-]+)(\.php)?

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

to uri 'redirect:/~george/site/.fiona/core/gateway.php' 127.0.0.1 - - [05/Oct/2011:08:47:37 --0400] [localhost/sid#20f41ce8][rid#21103668/initial] (1) [perdir /home/george/public_html/site/] pass through redirect:/~george/site/.fiona/core/gateway.php

localhost/~george/site/login.php

The links without the .php extension seem to make the initial redirect successfully, however, for some reason they appear to be unable to reroute to the absolute path.

I am by no means an expert on mod_rewrite, so there could very well be other issues here. Any ideas would be great.

EDIT
Based on Marius' answer, I believe I've narrowed this down to an issue with mod_userdir in combination with mod_rewrite. Moving the site to /var/www resolves the problem. I would still like to get this working in my public_html directory.

EDIT
Marius lead me closer to the solution in sites enabled. It turns out the problem was that MultiViews (allows apache to interpret index as index.php) was not enabled for user directories. Adding the following to my default sites enabled (/etc/apache2/sites-enabled/000-default) resolved the issue with .php extensions, but disables mod_rewrite.

My entire sites enabled follows

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

溺ぐ爱和你が 2024-12-15 07:22:08

在使用“userdir”模块(使您能够使用〜用户名的模块)时,我看到了很多这样的问题。您可以使用不使用 userdir 模块的“正常”目录尝试完全相同的操作吗?

只需使用以下结构重新创建您的网站:

marius@debiansrv:~/public_html/htaccesstest$ find
./.菲奥娜
./.菲奥娜/核心
./.fiona/core/gateway.php
./.htaccess

这里的 htaccess 文件与你的 100% 相同,并且工作正常。您可以在这里检查:
http://home.goodworkaround.com/~marius/htaccesstest/

您是否使用“ .fiona”作为文件夹名称?我怀疑你可能使用“fiona”。另外,如果不是这种情况,您应该从 Apache 粘贴站点设置。

I have seen a lot of these problems when using the "userdir" module (the module that makes you able to use ~username). Could you try this exact same thing with a "normal" directory, that is not using the userdir module?

Just re-created your site with the following structure:

marius@debiansrv:~/public_html/htaccesstest$ find
./.fiona
./.fiona/core
./.fiona/core/gateway.php
./.htaccess

Here the htaccess file is 100% the same as yours, and it works fine. You can check this here:
http://home.goodworkaround.com/~marius/htaccesstest/

Are you using ".fiona" as folder name? I suspect you may be using "fiona". Also, if this is not the case, you should paste the site settings from Apache.

柠檬心 2024-12-15 07:22:08

事实证明问题出在我的网站启用文件上。显然用户目录没有正确配置以允许 mod_rewrite 工作。复制 /var/www/ 的 VirtualHost 设置并进行少量编辑即可解决该问题。

<Directory /home/*/public_html>
    Options Indexes FollowSymLinks
    AllowOverride all
    Order allow,deny
    allow from all
</Directory>

It turns out the issue was with my sites enabled file. Apparently user directories were not configured properly to allow mod_rewrite to work. Copying the VirtualHost settings for /var/www/ with minor edits resolved the issue.

<Directory /home/*/public_html>
    Options Indexes FollowSymLinks
    AllowOverride all
    Order allow,deny
    allow from all
</Directory>
后来的我们 2024-12-15 07:22:08

它将查找您托管文件的基本目录相对于 URL 的位置。因此,如果您的网站实际上位于 http://example.com/~george/site/,你的 RewriteBase 是正确的。之后,它将在该目录中查找某些内容,然后根据您的规则在 RewriteBase/.fiona/core/gateway.php 中查找,但找不到。我相信,如果您将 .fiona 目录放在 site/ 中,它应该可以工作。

It will be looking for what the base directory of where you are hosting the files is located, relative to the URL. So if your site is actually at http://example.com/~george/site/, your RewriteBase would be correct. After that, it will be looking for something in that directory, and then based on your rules, at RewriteBase/.fiona/core/gateway.php, which it can't find. I believe that if you put the .fiona directory in site/, it should work.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文