mhonarc-dev

[approved] Adding support for euc-jp

2003-06-24 09:19:29
Hi,

I did a quick and dirty hack to make it possible for MHonArc to
generate all the pages in EUC-jp charset.  This has an advantage over
currently available mechanism of generating iso-2022-jp pages since
users can put Japanese character in the resource file using EUC-jp.
(If you do that using iso-2022-jp, Perl gives you warnings.)

After placing eucjp.pl, which is atached below, in your MHonArc
directory, you just say in your resource file:

<textencode>
euc-jp; MHonArc::Encode::from_to; MHonArc/Encode.pm
</textencode>
<CharsetConverters>
euc-jp; euc_jp::str2html; eucjp.pl
</CharsetConverters>
<textclipfunc>
euc_jp::clip; eucjp.pl
</textclipfunc>

And you can include Japanese text in the generated pages without any
problem, as long as you use euc-jp.

I referred to iso2022jp.pl when I wrote this.  If this looks
appropriate, please consider including it in the distribution.

     Cheers,
Max

ps: I'm not subscribed to the mhonarc-dev list, so please Cc me when
you reply to this message.

Attachment: eucjp.pl
Description: Binary data

<Prev in Thread] Current Thread [Next in Thread>
  • [approved] Adding support for euc-jp, Masafumi NAKANE <=