Re: [Maypole-dev] Strange automatic character conversion effect in Maypole

From: Kester Habermann (kester.habermann at gmail.com)
Date: Tue Dec 14 2004 - 23:28:57 GMT


Hi Simon,

On Tue, 14 Dec 2004 23:15:53 +0000, Simon Flack <sf at flacks.net> wrote:

thanks for the quick answer!

> I've experienced this before with perl5.6.1. I /think/ it's XML::Parser
> that does that conversion.

The XML::Simple sets the flag, that's why it's set after my XMLin call. ok.

But my question was how come does Maypole convert the normal template
files and the variable that are filled into the templates into utf8? I
can't see where XML::Parser called
in the processing chain of Maypole::handler and Template::proccess.

> > sub additional_data {
> > my $r = shift;
> >
> > $r->{document_encoding} = "iso-8859-15";
> > }
> >
> > Is that the way it is supposed to be done or is there a better way?
>
> Yes. Or using the accessor: $r->document_encoding('iso-8859-15')

OK. I was just wandering if there's a better place than
additional_data for this, like the initialization.

Kester.



This archive was generated by hypermail 2.1.3 : Thu Feb 24 2005 - 22:25:57 GMT