Section – Rewrite Response Redirect Location

Section - Rewrite Response Redirect Location

Rewrite option to modify the HTTP redirect location header sent from the back-end server before it is sent to the client. Rewriting the location redirect header may be necessary if the application creates absolute or incorrect location headers because it is not reverse proxy compatible.

Example:

Rewrite Response Redirect Location:
^(https?://%BACKENDHOST%)?/%BACKENDPATH%(/.*)?$

Replace with:
/%ENTRYPATH%$2

This example translates absolute and relative back-end URLs into an external absolute path.