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

pkp/citationStyleLanguage#118 remove double encoding in citations #122

Merged
merged 1 commit into from
Jul 12, 2024

Conversation

bozana
Copy link
Collaborator

@bozana bozana commented Jun 27, 2024

s. #118
and #95

This issue solves the problem with double HTML encodings in citations:
For settings that we store with HTML encodings (like publication title and abstract) we need to use htmlspecialchars_decode, because the CSL library that we use also encodes the HTML characters.
I have only removed the HTML encoding from settings where needed (realized through testing).
Strangely for the other settings, like for example 'pages', it does not matter if we use htmlspecialchars or not -- the result is always the same :-O -- so I will leave them as they are for now.

Copy link
Contributor

@jonasraoni jonasraoni left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @bozana, I've tested locally and I saw the underlying library does escape data, so we really don't need to do it on our side.
I've just left a note to fix a side-bug instead of unescaping data that should be already in a text format.

@bozana
Copy link
Collaborator Author

bozana commented Jun 28, 2024

Hi @jonasraoni, I added the PRs for publication title in text format here: pkp/pkp-lib#10135 and adapted the changes here accordingly.
Could you please take another look?
Thanks a lot!

@bozana bozana merged commit 5179eba into pkp:stable-3_4_0 Jul 12, 2024
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

Successfully merging this pull request may close these issues.

None yet

3 participants