i18n:problem_children
Differences
This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
i18n:problem_children [2008/01/20 08:15] – created dbs | i18n:problem_children [2025/08/02 18:08] (current) – Removing outdated XUL client information; adding Launchpad links sleary | ||
---|---|---|---|
Line 1: | Line 1: | ||
+ | ======Internationalization challenges====== | ||
+ | See [[https:// | ||
+ | |||
+ | =====Unfriendly Forms==== | ||
+ | |||
+ | A few forms are designed as "fill in the blank" English sentences, which won't translate well. | ||
+ | |||
+ | See [[https:// | ||
+ | |||
+ | =====MARC editor suggestions===== | ||
+ | There is a giant file of field labels for the MARC editor that has been generated from the Library of Congress electronic MARC21 documentation. Where translated versions of the MARC21 standard are available, we will have to create scripts to parse and build the equivalent translations. Depending on the license of the translated work, the translations may not be able to be distributed as part of Evergreen and may have to be built by each Evergreen site instead (unless an Evergreen vendor negotiates a redistribution license with the copyright owner): | ||
+ | |||
+ | * [[http:// | ||
+ | * [[http:// | ||
+ | |||
+ | |||
+ | =====Hard-coded locales in application code===== | ||
+ | |||
+ | Need to check for and correct code like the following in '' | ||
+ | <code perl> | ||
+ | if ($format eq ' | ||
+ | print " | ||
+ | if ($type eq ' | ||
+ | print " | ||
+ | if ($type eq ' | ||
+ | return 302; | ||
+ | |||
+ | } | ||
+ | </ | ||
+ | Something like the following may work: | ||
+ | <code bash> | ||
+ | find Open-ILS/ | ||
+ | </ | ||
+ | |||
+ | //[ We need to teach Apache to pass the locale to mod_perl handlers (maybe it can already? %ENV is fine) and move supercat under / | ||
+ | |||
+ | =====Calendar widgets===== | ||
+ | |||
+ | See [[https:// | ||
+ | |||
+ | =====Logic relying on parsing English text===== | ||
+ | From '' | ||
+ | <code javascript> | ||
+ | ' | ||
+ | JSAN.use(' | ||
+ | try { | ||
+ | if (node.value == ' | ||
+ | var pattern = node.value.match(/ | ||
+ | if (pattern) { | ||
+ | var today = new Date(); | ||
+ | var todayPlus = new Date(); todayPlus.setTime( today.getTime() + 24*60*60*1000*pattern[1] ); | ||
+ | node.value = util.date.formatted_date(todayPlus," | ||
+ | } | ||
+ | if (! util.date.check(' | ||
+ | if (util.date.check_past(' | ||
+ | if ( util.date.formatted_date(new Date(),' | ||
+ | return true; | ||
+ | } catch(E) { | ||
+ | throw(E); | ||
+ | } | ||
+ | }, | ||
+ | </ | ||
+ | The problem here is that we're running a regex against an English string. A couple of approaches to solving this problem: | ||
+ | * One regex per locale (brittle, perhaps, and requires regex knowledge that the average translator probably won't have) | ||
+ | * Create a parallel hidden node that contains the English string and parse that instead, while the localized version is displayed (a bit tricky, but doesn' | ||
+ | * Set the value as an attribute of the node and parse that instead (possibly using a simple math notation like '' | ||
+ | |||
+ | ===== Hardcoded strings in Perl modules ===== | ||
+ | |||
+ | [[http:// | ||
+ | sub bookbag_feed { | ||
+ | ... | ||
+ | if ($type eq ' | ||
+ | print " | ||
+ | join('&', | ||
+ | " | ||
+ | return 302; | ||
+ | } | ||
+ | ... | ||
+ | $feed-> | ||
+ | ... | ||
+ | $feed-> | ||
+ | OPAC => | ||
+ | '/ | ||
+ | join('&', | ||
+ | ' | ||
+ | ); | ||
+ | } | ||
+ | </ | ||
+ | |||
+ | =====Org Unit shortnames===== | ||
+ | Some code invokes the '' | ||
+ | ' | ||
+ | if (my.circ) { | ||
+ | return data.hash.aou[ my.circ.circ_lib() ].shortname(); | ||
+ | } else { | ||
+ | if (my.acp.circulations()) { | ||
+ | return data.hash.aou[ my.acp.circulations()[0].circ_lib() ].shortname(); | ||
+ | } else { | ||
+ | return ""; | ||
+ | } | ||
+ | }</ |