-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Fix incorrect script name when Drupal uses a domain + subdir #3166
Conversation
The URLs generated by Drupal core Url class are still wrong though. |
The simplest way to reproduce the issue is to put the following code to some command and call it with
Instead |
tests are failing, unfortunately. |
Still needed? |
The bug still exists in |
You must use Drupal 8.4.4 (release yesterday) if you are using PHP 7.2. Earlier versions did not support 7.2. |
I am using the latest code form 8.5.x Git branch. Is Drush itself compatible with PHP 7.1 and PHP 7.2? It appears it is not tested against these PHP versions. |
Since this issue most likely is the cause for the missing subdir when using
returns "http://nonexisting.domain/user/reset/1/[...]" without the subdir in the URL (when using Drush 9.1.0). |
Github updated the PR so its up to date with master. Still is failing tests tho. |
FYI #3553 just fixed this. |
Thanks @weitzman |
It works for sub-directories, if there is a trailing slash: No trailing slash, subdir not included:
With trailing slash, subdir is included:
|
… a domain + subdir without scheme.
… a domain + subdir without scheme.
… a domain + subdir without scheme.
This only happens when Drupal is installed in subdirectory and site URL is passed by means global uri option like follows.
drush <CMD> --uri=http://localhost/subdirectory
Because of wrong script name some Drupal global variables ($base_path and $base_url) get wrong values.