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

Wrong html entities in <title> tag after PR 7463 #7497

Closed
jagbarcelo opened this issue Nov 3, 2020 · 5 comments · Fixed by #7503
Closed

Wrong html entities in <title> tag after PR 7463 #7497

jagbarcelo opened this issue Nov 3, 2020 · 5 comments · Fixed by #7503
Assignees

Comments

@jagbarcelo
Copy link
Contributor

We have spotted an issue with PR 7463.

Before this change, our <title> tags with special characters were rendered just fine (plain raw text). Now we have them shown as hex html entities but the & character is being escaped, so they are not rendered properly:

image

If you go to the actual html output of the page it has:

image

but it should have:
<title>P&#xE1;gina de prueba - my-site</title>

Summing up, the & character in the &#xE1; entity should not be escaped to &amp;xE1;

BTW, the <title> tag in TheBlogTheme is rendered with (which is fine):
<title>{{ "PageTitle" | shape_new | shape_stringify }}</title>

//cc @jtkech

@jagbarcelo jagbarcelo changed the title Undesired html entities in <title> tag after PR 7463 Wrong html entities in <title> tag after PR 7463 Nov 3, 2020
@hishamco
Copy link
Member

hishamco commented Nov 3, 2020

Encoding issue, I will fix this

@sebastienros
Copy link
Member

How is your title rendered since you mention that it's fine in the Blog Theme with <title>{{ "PageTitle" | shape_new | shape_stringify }}</title>

@jtkech
Copy link
Member

jtkech commented Nov 3, 2020

See my last comment in #7498

@jagbarcelo
Copy link
Contributor Author

I meant that TheBlogTheme is correct in using <title>{{ "PageTitle" | shape_new | shape_stringify }}</title>, not that the output of that was correct (which was not).

@sebastienros
Copy link
Member

@jagbarcelo thanks for the confirmation. Checking @jtkech 's answer now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
4 participants