forrest-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Pedro I. Sanchez" <psanc...@colcan.biz>
Subject How to avoid hard-coding site-visible message strings in skin files
Date Wed, 01 Jun 2005 20:30:10 GMT
Hello,

A few days ago I added issue FOR-506 on this topic. This is my original
message:

  "Text strings like "Copyright", "Published", and "Search" are
   hardcoded into skin files like site2xhtml.xsl. When creating web
   sites in languages other than English the web developer is forced
   to create local versions of these skin files with the appropriated
   translations.

   Instead, the DTD for the skinconf.xml should be improved to allow
   these translations to be specified in this file. This would make
   Forrest much easier to use."

Ross suggested the following as an example of a possible solution:

<i18n lang="en">
  <token name="lastPublished" value="Last Published"/>
  <token name="copyright" value="Copyright"/>
</i18n>
<i18n lang="??">
  <token name="lastPublished" value="???????"/>
  <token name="copyright" value="???????"/>
</i18n>

This would work for me as long as I can also specify the language
manually with something like

<i18n lan="en" />

And this, because at this moment I am more interested in a uni-lingual
(non-English) web site rather than in a multi-lingual one. I believe
the former is by far the most common case.

Another possibility could be something like this, totally independent
of a "lang" setting and just driven by the skin:

<skinlabels name="pelt">
  <keyword name="lastPublished" value="???????"/>
  <keyword name="copyright" value="???????"/>
</skinlabels>

For a multi-lingual site I would like to have something that
dynamically changes the skin and content of the site. But that is
a more elaborated solution that is probably being addressed by
the i18n team (?). I'm not sure if a solution that simply
gets the "hard-coded" labels out of the way has to necessarily
be part of the i18n "framework".

Anyway, with your help and guidance I'd like to put some effort
implementing a solution of some kind.

Comments?

-- 
Pedro



Mime
View raw message