commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Henri Yandell <flame...@gmail.com>
Subject Re: [lang] Bugs of StringEscapeUtils.escapeHtml()?
Date Wed, 16 Mar 2005 04:47:16 GMT
Relatively clueless about the code (Gary and Alex were the main
authors, Alex isn't very active now).

If I'm understanding correctly, then the issue is that the code is
escaping values that are not specifically listed in the spec listed
below. Scanning the code, it looks like the cause is on line 611 of
the current version, if entityName is null (ie it is not specified)
and it is > 0x7f, then it escapes the value as a number. The same
issue I presume is in the unescape side.

Given that the code is pretty focused on display by a browser, failure
to fit IE and Firefox's feature-set seems like a pretty critical
problem.

Still. I think it's going to be better to work on a 2.1 release and
then focus on this issue, than to try and squeeze this one in just
before release. If you can provide a patch and unit test, then I'm
sure we'll be able to apply it to head as soon as the release goes
out. Otherwise a bug report would still be great and it'll be gotten
to eventually.

Hen

On Wed, 9 Mar 2005 11:28:17 +0800, Carfield Yim <carfield@gmail.com> wrote:
> I guess so.... seem IE and firefox won't change the escaped multibyte
> characters back to human readable character to our user. And see it is
> not fit to the specification?
> 
> http://www.w3.org/TR/REC-html40/sgml/entities.html
> 
> On Tue, 8 Mar 2005 22:14:39 -0000, Stephen Colebourne
> <scolebourne@btopenworld.com> wrote:
> > Is that a problem?
> > Stephen
> >
> > ----- Original Message -----
> > From: "Carfield Yim" <carfield@gmail.com>
> > > Other than escapeHTML entities like space and < , all multibyte
> > > Characters like Chinese, Japanese and Russian will escaped.
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: commons-user-help@jakarta.apache.org
> >
> >
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-user-help@jakarta.apache.org
> 
>

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org


Mime
View raw message