Skip to content

Commit 5a9445e

Browse files
committed
Rewrote first sentence to make the problem this section tries to solve more clear.
1 parent b155d72 commit 5a9445e

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

deployment/proxies.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -162,10 +162,10 @@ trusted proxies.
162162
Reverse proxy in a subpath / subfolder
163163
--------------------------------------
164164

165-
If you configure the reverse proxy in such a way that the Symfony application is
166-
mapped in a subpath / subfolder instead of the root path of the web host, you will need to
167-
pass the prefix to Symfony by setting the ``X-Forwarded-Prefix`` header.
168-
This is required for Symfony to generate the correct URLs. The header can normally be configured
165+
If you a running a Symfony application behind a reverse proxy, where the application is served in a subpath / subfolder,
166+
you might encounter the problem that Symfony generates incorrect URLs, which ignore the subpath / subfolder of the reverse proxy.
167+
To fix this, you need to pass the subpath / subfolder route prefix of the reverse proxy to Symfony by
168+
setting the ``X-Forwarded-Prefix`` header. This is required for Symfony to generate the correct URLs. The header can normally be configured
169169
in your reverse proxy configuration. Configure ``X-Forwared-Prefix`` as trusted header to be able to use this feature.
170170

171171
The ``X-Forwarded-Prefix`` is used by Symfony to prefix the base URL of request objects, which is

0 commit comments

Comments
 (0)