symfony/symfony-standard — pull request #503 by Tobion (2013-03-01 11:44:21+00:00)
Title: redirect /app.php to prevent duplicate content

This time it's compatible with Apache < 2.3.9 by not using the END flag. It also features default compatibility with apache aliases (inspired by [Zend](https://github.com/zendframework/ZendSkeletonApplication/blob/master/public/.htaccess)). And it improves the rewriting performance for the homepage by preventing the process to apply to each DirectoryIndex file.

I tested it thoroughly and also debugged apache rewriting to see what's happening.
May be good if someone else can confirm all works. Examples:

With vhost:
- http://symfony-standard.lo/app.php -> redirect -> http://symfony-standard.lo/
- http://symfony-standard.lo/app.php/ -> redirect -> http://symfony-standard.lo/
- http://symfony-standard.lo/app.php/foo/bar -> redirect -> http://symfony-standard.lo/foo/bar
- http://symfony-standard.lo/app.phpF-> stays as-is

With alias:
- http://localhost/symfony-standard/app.php -> redirect -> http://localhost/symfony-standard/
- http://localhost/symfony-standard/app.php/ -> redirect -> http://localhost/symfony-standard/
- http://localhost/symfony-standard/app.php/foo/bar -> redirect -> http://localhost/symfony-standard/foo/bar
- http://localhost/symfony-standard/app.phpF-> stays as-is