-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
Symfony\Component\HttpFoundation\Request::prepareBaseUrl() is empty #34866
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
This was referenced Dec 6, 2019
@fabpot Please reopen, this is a major issue and it affects all users whose have some URL part (like |
mvorisek
added a commit
to mvorisek/symfony
that referenced
this issue
Oct 17, 2020
mvorisek
added a commit
to mvorisek/symfony
that referenced
this issue
Oct 17, 2020
mvorisek
added a commit
to mvorisek/symfony
that referenced
this issue
Oct 17, 2020
mvorisek
added a commit
to mvorisek/symfony
that referenced
this issue
Oct 17, 2020
mvorisek
added a commit
to mvorisek/symfony
that referenced
this issue
Oct 17, 2020
mvorisek
added a commit
to mvorisek/symfony
that referenced
this issue
Oct 17, 2020
derrabus
added a commit
that referenced
this issue
Nov 15, 2020
…vorisek) This PR was merged into the 4.4 branch. Discussion ---------- [HttpFoundation] Fix for virtualhosts based on URL path | Q | A | ------------- | --- | Branch? | 3.4 | Bug fix? | yes | New feature? | no | Deprecations? | no | Tickets | Fix #34866 | License | MIT | Doc PR | no This PR fixes base URL detection when: - virtualhost is based on URL path - AND local path does not match that URL virtual host path prefix fix covered with tests Commits ------- 75ff868 [HttpFoundation] Fix for virtualhosts based on URL path
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Description
When webserver (file) root is more specific than the request (URL) root, the current
Symfony\Component\HttpFoundation\Request::prepareBaseUrl()
methodsymfony/src/Symfony/Component/HttpFoundation/Request.php
Line 1766 in 4a9926a
This is core method and it needs to be fixed asap.
How to reproduce
Webserver config: serve requests with path
^/ps/*$
fromC:/data/psmigr/ps_dev/
root directoryCurrent results
http://localhost/ps/pslrel18/adminX/
http://localhost/ps/pslrel18/adminX/something
http://localhost/ps/pslrel18/adminX/index.php
Notice the last
var_dump
in each result.Expected results
http://localhost/ps/pslrel18/adminX/
http://localhost/ps/pslrel18/adminX/something
http://localhost/ps/pslrel18/adminX/index.php
The text was updated successfully, but these errors were encountered: