[pmwiki-users] i18n and iso-8859-13
Algis Kabaila
akabaila at pcug.org.au
Wed Mar 30 01:59:20 CST 2005
Hi,
1. Introduction.
I grew up (and finished High School) in Lithuania - many years ago. In
addition to PmWiki that I run for PCUG-TIP (PC Users' Group Canberra - The
Internet Project, with over 1,000 members), I run a PmWiki at my HAN (Home
Area Network). All my PC's run on Linux, the one called "server" runs Apache
v 2.0.49 web server, and php v. 4.3.4.
My home PmWiki is used to organize my notes - I do write to newspapers either
in English or Lithuanian. Lithuanian standard is iso-8859-13. The websites
in Lithuania use mostly windows-1257 "standard", which is almost identical to
iso-8859-13. The W3C recommended alternative is utf-8. As I have not found
any extensive use of utf-8 in Lithuanian, I want to use iso-8859-13.
Unfortunately, with utf-8 I only could talk successfully mainly to myself.
iso-8859-13 uses the same character set in the range of 0 to 127 as
iso-8859-1, so that using iso-8859-13 does not interfere with written
English.
2. Implementation.
After downloading the Pm's i18n.tgz and expanding it, I "doctored" the
iso-8859-9 implementation, renaming it xlpage-iso-8859-16.php. The contents
of this "doctored" file is as follows:
<?php if (!defined('PmWiki')) exit();
/* Copyright 2005 Patrick R. Michaud (pmichaud at pobox.com)
This file is part of PmWiki; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published
by the Free Software Foundation; either version 2 of the License, or
(at your option) any later version. See pmwiki.php for full details.
*/
global $HTTPHeaders;
$HTTPHeaders[] = "Content-type: text/html; charset=iso-8859-13;";
?>
I then copied xlpage-iso-8859-13.php file to the .../scripts directory and the
added a line in the .../local/config.php file as follows:
include_once('scripts/xlpage-iso-8859-13.php');
This enables me to write with Lithuanian diacriticals - and read it with
the correct glyphs.
3. Questions.
3.1 Considering that my knowledge of php is very close to zilch, is the above
procedure "safe"?
3.2 I notice that there are some pages waiting for translation into
Lithuanian: PmWikiLt.PmWikiLt, PmWikiLt.XLPage. If no one else is doing it,
I would like to start the translation. As the files seem to be one long
line, it would be very awkward to handle. I would probably write a small
script (in Python) that would split up the text into meaningful lines and
probably write another script to merge it all back into one amorphous mass.
However, that is probably reinvention of a wheel - is there some "standard"
way of handling this task.
I must add that my effort would be very slow on account of my many other
commitments, diminishing ability to work effectively and last, but not least,
because of my lack of familiarity with current Lithuanian terminology -
computers were not even dreamed of when I did my Lithuanian studies.
This email is mainly addressed to Pm, whose efforts are greatly appreciated,
but I am sending it to the list in case there is some other Lithuanian
speaker already on the way with translations.
Also, there no doubt are many others who have used PmWiki for languages other
than English. Their shared experience and knowledge would be most welcome.
TIA,
Sincerely, Al.
--
Algis Kabaila
http://www.pcug.org.au/~akabaila
More information about the pmwiki-users
mailing list