Skip to content

Conversation

@candrews
Copy link
Contributor

Based on the encoding, in many cases, many characters do not need to be transformed into entities.
For instance, when the encoding is UTF-8, there are only 5 characters that needs to become entities
and shouldn't appear in their literal forms.

See SPR-9293

Based on the encoding, in many cases, many characters do not need to be transformed into entities.
For instance, when the encoding is UTF-8, there are only 5 characters that needs to become entities
and shouldn't appear in their literal forms.

See SPR-9293
@candrews
Copy link
Contributor Author

I have signed and agree to the terms of the SpringSource Individual Contributor License Agreement.

@candrews
Copy link
Contributor Author

@bclozel @snicoll @jhoeller Can someone please review (and hopefully merge) this pull request? I'd really like to see it included at some point and (imho) it's not really a big change.

bclozel added a commit that referenced this pull request Oct 21, 2014
This commit adds new htmlEscape methods that take the character encoding
as a parameter. According to specs and recommendations, the list of
chars to be html escaped depends on the encoding used in the response.
If the current char encoding supports chars natively, we shouldn't
escape those; of course, reserved chars (<,>,',",&) should always be
escaped.

See: http://www.w3.org/TR/html4/sgml/entities.html#h-24.3
See: #385 by @candrews

Issue: SPR-9293
@bclozel
Copy link
Member

bclozel commented Dec 31, 2014

Merged with 369cabf

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.

3 participants