Open artecnico opened 5 days ago
Hi. I can't replicate your issue. I don't see the characters in the upper corner, as you indicate. However, it is true that in the opengraph tags of the source code, double quotes have an undesirable effect on said source code.
I attached a screenshot to show double quotes in the title, without observing any strange characters in the top corner.
At the end, I managed to replicate the error, just adding ">
to the end of a page title. It seems that with those characters, they are displayed in the body of the page instead of in the head.
This does not happen with other templates where the |e('html')
filter is not applied to the title or description of the metadata. I will have to continue investigating, although adding this filter solves the problem for now.
Thanks for your contribution.
If you enable the "Summary" option for the blog posts and write some special characters in the post title/body (like double quotes " or > for example), then the HTML is broken and some chars are show in the upper-left corner of the page.
If you examine the source code you can see it is broken because those special chars are not correctly HTML encoded in the Open Graph metatags.
To fix this you've to add |e('html') in the metadata.html.twig just before the truncate calls: