[Catalyst-dev] my "ongoing" projects

Jonathan Rockway jon at jrock.us
Tue Oct 10 16:31:12 CEST 2006


This should make the plugin a bit more sane:

http://use.perl.org/comments.pl?threshold=0&mode=nested&commentsort=0&op=Change&sid=33258

(I really should keep up on C<use Perl;> journals :)

Jonathan Rockway wrote:
> Here are some things I'm working on -- feel free to comment:
> 
> 1) C::P::Unicode should really be
> C::P::DealWithWhateverEncodingsYourUsersUse (or C::P::Encode::DWIM).
> That's a long name, but here's what I am trying to get the module to do:
> 
> On request, see what charset the request is in, and convert that to utf8
> strings (with is_utf8 set, of course).
> 
> On response, remember the charset that the user's request was in, and
> encode perl's strings to that charset.  If that fails, fallback to
> UTF-8.  The issue here is that we have to change the headers.  If the
> application sets the content-type to be "application/xhtml+xml;
> charset=foobar", then we'll have to ignore the application's explicit
> request and encode to something else.  Maybe we should just ignore the
> user's preference and choose the charset based on that header.  (In
> addition to that, people could be setting the charset in <meta> tags,
> but I don't think anyone does that anymore.)

-- 
package JAPH;use Catalyst qw/-Debug/;($;=JAPH)->config(name => do {
$,.=reverse qw[Jonathan tsu rehton lre rekca Rockway][$_].[split //,
";$;"]->[$_].q; ;for 1..4;$,=~s;^.;;;$,});$;->setup;



More information about the Catalyst-dev mailing list