Skip to content

[Framework] clearified base_uri behavior with extra examples #17439

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

Merged
merged 1 commit into from
Dec 1, 2022

Conversation

c33s
Copy link
Contributor

@c33s c33s commented Nov 19, 2022

added some more examples with an extra directory depth. this should better document the behavior for the base_uri parameter in combination with the leading slash in the relative url.

took some "reallife" url as example as foo/bar/baz wouldn't be so clear with only one letter difference between bar and baz. i only added one "foo" url and the urls with api in the path, the others rows are only changed because of the new intending. even if some of the examples are redundant i personally would keep them as the extra examples clearify the behavior.

cost me quite some time to figure that out. hope this small addition helps people not to fall for the same.

related to: symfony/symfony#39724

@carsonbot carsonbot added this to the 6.2 milestone Nov 19, 2022
@c33s c33s changed the title [Framework] clearified base_uri behaviro with extra examples [Framework] clearified base_uri behavior with extra examples Nov 19, 2022
@OskarStark
Copy link
Contributor

@nicolas-grekas, given the examples, is this really the expected behavior?
Even if this is correct, it is quite confusing, isn't it?

@nicolas-grekas
Copy link
Member

nicolas-grekas commented Nov 19, 2022 via email

@OskarStark
Copy link
Contributor

Thanks for the feedback

@javiereguiluz javiereguiluz changed the base branch from 6.2 to 5.4 December 1, 2022 16:24
@javiereguiluz javiereguiluz requested a review from xabbuh as a code owner December 1, 2022 16:24
@javiereguiluz javiereguiluz force-pushed the added-another-base-uri-example branch from 5abeded to 97b942f Compare December 1, 2022 16:24
@javiereguiluz javiereguiluz merged commit 3efacf8 into symfony:5.4 Dec 1, 2022
@javiereguiluz
Copy link
Member

Julian, thanks for improving these examples in the docs.

@c33s
Copy link
Contributor Author

c33s commented Dec 2, 2022

happy to help

@King2500
Copy link
Contributor

For people coming from Google to this issue:
Here is the actual documentation for base_uri resolving:
https://symfony.com/doc/current/reference/configuration/framework.html#base-uri

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants