Laravel is "listening" to index.php string anywhere in the URL Laravel is "listening" to index.php string anywhere in the URL laravel laravel

Laravel is "listening" to index.php string anywhere in the URL


The problem is inside the Symfony Request class and how it determines the base URL. Basically it assumes that if you have a request like aaa/index.php that your currently running script (named index.php) is inside the directory aaa takes aaa/index.php as base URL.
Later it will then be stripped from the actual request URI.

I fixed this unwanted behavior with a pull request that is currently under review. I will update this post as soon as it gets merged.


Same issue i was facing in laravel 3 when i was skipping public from url. then i have placed another htaccess file in public folder.

RewriteEngine onRewriteBase /RewriteCond %{REQUEST_FILENAME} !-fRewriteCond %{REQUEST_FILENAME} !-dRewriteRule ^(.*)$ index.php/$1 [L]