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

Escape not required for meta description #699

Closed
corentinbettiol opened this issue Mar 11, 2022 · 0 comments · Fixed by #726
Closed

Escape not required for meta description #699

corentinbettiol opened this issue Mar 11, 2022 · 0 comments · Fixed by #726

Comments

@corentinbettiol
Copy link
Contributor

Description

Djangocms-blog is escaping meta description in get_description (in Post and BlogCategory), but django-meta already escape all meta tags.

The result is that keywords (and other meta tags that don't use meta description) are single escaped (in django-meta), and that description (and all other meta tags that use meta description as a source) are double escaped (one time in djangocms-blog, and one time in django-meta):

image
The & is replaced by &.

Steps to reproduce

  • Create a blog post,
  • Add a meta description with some chars that are encoded (like '),
  • Add keywords with the same chars,
  • Publish the blog post,
  • See the source code of the page.

Versions

All versions since this commit (2014).

Expected behaviour

Meta description and keywords should be encoded only one time.

Actual behaviour

Meta description and related meta tags are encoded two times:

  • meta description
  • og description
  • twitter description
  • [...]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
1 participant