codeguy/Slim — pull request #475 by xjunior (2013-01-13 23:58:15+00:00)
Title: PATH_INFO in url rewritten applications with public directory

PATH_INFO was being set to "/" on most of the situations, leading to misrouting.

Example app would be:

/
-- .htaccess
-- webroot
-- index.php

.htaccess file:

RewriteEngine On

RewriteRule ^\.htaccess$ - [F]

RewriteCond %{REQUEST_URI} ^/(javascript|stylesheet|images)/.*$
RewriteRule ^(.*)$ /webroot/$1 [L]

RewriteCond %{REQUEST_URI} !^/webroot/.*$
RewriteRule ^(.*)$ /webroot/index.php [QSA,L]