[
https://issues.apache.org/jira/browse/LANG-122?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Sebb updated LANG-122:
----------------------
Description:
The official HTML character entity spec does not include the popular
"'"
entity name for the single quote character '. the StringUtils class correctly
follows this behavior, leaving single quotes alone. However, many developers
incorrectly assume that ' will get escaped into ' (I was one!) and we
can
help them by clarifying this in the Javadoc.
The following could be appended to the method Javadoc:
Note: Not all common HTML entity names are formally included in the standard
specification (http://www.w3.org/TR/REC-html40/sgml/entities.html, as listed
below). This method follows the standard, and thus does not escape the
single-quote ' character into &apos.
was:
The official HTML character entity spec does not include the popular
"'"
entity name for the single quote character '. the StringUtils class correctly
follows this behavior, leaving single quotes alone. However, many developers
incorrectly assume that ' will get escaped into ' (I was one!) and we can
help them by clarifying this in the Javadoc.
The following could be appended to the method Javadoc:
Note: Not all common HTML entity names are formally included in the standard
specification (http://www.w3.org/TR/REC-html40/sgml/entities.html, as listed
below). This method follows the standard, and thus does not escape the
single-quote ' character into &apos.
> [lang] EscapeUtil.escapeHtml() should clarify that it does not escape ' chars
> to '
> ---------------------------------------------------------------------------------------
>
> Key: LANG-122
> URL: https://issues.apache.org/jira/browse/LANG-122
> Project: Commons Lang
> Issue Type: Bug
> Affects Versions: 2.1
> Environment: Operating System: All
> Platform: All
> Reporter: Dov Wasserman
> Priority: Minor
> Fix For: 2.2
>
>
> The official HTML character entity spec does not include the popular
> "'"
> entity name for the single quote character '. the StringUtils class correctly
> follows this behavior, leaving single quotes alone. However, many developers
> incorrectly assume that ' will get escaped into ' (I was one!) and
> we can
> help them by clarifying this in the Javadoc.
> The following could be appended to the method Javadoc:
> Note: Not all common HTML entity names are formally included in the standard
> specification (http://www.w3.org/TR/REC-html40/sgml/entities.html, as listed
> below). This method follows the standard, and thus does not escape the
> single-quote ' character into &apos.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.