-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Description
Bug Report
Environment
Zola version: 0.15.3
Expected Behavior
Tell us what should have happened.
When setting redirect_to on a section's _index.md to an external URL, the redirection page should redirect to the external URL.
Current Behavior
Tell us what happens instead of the expected behavior. If you are seeing an
error, please include the full error message and stack trace. You can get the
stacktrace of a panic by adding RUST_BACKTRACE=1 when running a zola command.
The site's base URL gets concatenated to the external URL: with a base URL at https://foo.com and redirect_to = "https://bar.com/something", the user gets redirected to https://foo.com/https://bar.com/something.
Step to reproduce
Please provide the steps to reproduce the issue.
If the issue is hard to reproduce, please provide a sample repository or sample
that triggers the bug.
-
Set the site's base URL to
https://foo.com -
Create an
_index.mdanywhere in a site's content, and set a redirection:+++ redirect_to = "https://bar.com/something" +++ -
Generate the site.
-
Open the section that you created.
You will get redirected to https://foo.com/https://bar.com/something.