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

Embedded image render hook does not retain fragment and query string #12468

Closed
jmooring opened this issue May 7, 2024 · 1 comment · Fixed by #12469
Closed

Embedded image render hook does not retain fragment and query string #12468

jmooring opened this issue May 7, 2024 · 1 comment · Fixed by #12469

Comments

@jmooring
Copy link
Member

jmooring commented May 7, 2024

Reference: https://discourse.gohugo.io/t/the-embeded-image-render-hook-removes-uri-fragment-of-src-attribute/49684

The embedded link render hook retains the fragment and query string...

{{- $href = .RelPermalink -}}
{{- with $u.RawQuery -}}
{{- $href = printf "%s?%s" $href . -}}
{{- end -}}
{{- with $u.Fragment -}}
{{- $href = printf "%s#%s" $href . -}}
{{- end -}}

But the embedded image render hook does not.

Copy link

github-actions bot commented Jun 1, 2024

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jun 1, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant