Skip to content
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

Blowfish series should use RelPermalink instead of Permalink in ToC #1916

Open
voigt opened this issue Jan 13, 2025 · 0 comments
Open

Blowfish series should use RelPermalink instead of Permalink in ToC #1916

voigt opened this issue Jan 13, 2025 · 0 comments

Comments

@voigt
Copy link
Contributor

voigt commented Jan 13, 2025

Describe the bug

Table of Contents of an article series uses permalinks instead of relative permalinks. This leads to the issue, that when compiled with a configured baseURL, links of the ToC are not working.

To Reproduce
Steps to reproduce the behavior:

  1. Create an article series
  2. Set baseURL = "https://christophvoigt.com/" in config.toml
  3. hugo serve
  4. Try to access a link in the series, it will link to a 404, as it points to https://christophvoigt.com/<path>, not https://localhost:<port>/path

Expected behavior

Link to the actual page, when served on localhost

Hugo & Blowfish versions

hugo v0.140.2+extended+withdeploy darwin/arm64 BuildDate=2024-12-30T15:01:53Z VendorInfo=brew

Additional context

I think the target of the <a href should be

...
        <a href="{{$post.RelPermalink}}">
...

instead of

...
        <a href="{{$post.Permalink}}">
...

At least this fixed the behavior for me.

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

No branches or pull requests

1 participant