[Html-widget] strange error with HTMLEscape filter when installing latest from CPAN

Carl Franks fireartist at gmail.com
Fri Dec 1 21:44:34 GMT 2006


On 01/12/06, Bernhard Graf <html-widget at augensalat.de> wrote:
> Carl Franks wrote:
>
> > Yeah, the latest version of HTML::Element has fixed the unicode
> > encoding problem, but it's introduced a questionable feature, in that
> > it won't encode any '&' which looks like it's already part of a
> > HTML-encoded intity.
> > This means the double-encoding test fails.
> >
> > I've been communicating with the author, he felt the feature was
> > needed, but I've pointed out that the previous behaviour of
> > HTML::Element was that it encoded everything except "~literal"
> > pseudo-elements, so the feature is unnecessary. I've not had a
> > response to that in the past couple days, but I'm hopeful that he'll
> > relent!
>
> I find this feature *very* usefull!
>
> Otherwise you have no chance to indent <options> in a <select> list:
>
> color
>   red
>   green
>   blue
> taste
>   sweet
>   bitter
>
> (done with leading &nbsp;)

That would be better done with an optgroup form field.

Or you could use the mentioned ~literal element, which ensures your
&nbsp; isn't encoded (if using HTML::Element for select options
doesn't yet work, patches welcome!)

Carl



More information about the Html-widget mailing list