cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Lassi Immonen <limmo...@malla.urova.fi>
Subject Re: Internationalization
Date Tue, 12 Dec 2000 09:27:11 GMT
Torsten Curdt wrote:
> 
> > Torsten Curdt wrote:
> > >
> > > > > > Conny,
> > > > > > Is there a discussion (or) plan to make small jar files
> > (either C1 or
> > > > > > C2) available for download
> > > > > > (or added to the xml-cocoon\lib in CVS)? To make it easier
> > > > for people to
> > > > > > use components like the
> > > > > > i18n Transformer/Processor. IMHO, i18n
> > Transformer/Processor is very
> > > > > > important for any
> > > > > > non-trivial, decent-sized site.
> > > > >
> > > > > The source file are available from the Infozone CVS. There are
> > > > no plans to
> > > > > make a sperate "i18" package. Anyway, it would only consist of two
> > > > > classes.
> > > > >
> > > >
> > > > Hi,
> > > >
> > > > I contributed quick port of I18nProcessor to Transformer a while ago.
> > > > But I can't see it in Infozones CVS yet.
> > > >
> > > > Anyway Giacomo has asked me to send I18nTransformer and LangSelector
> > > > action again, so I will do that after I have added some comments to
> > > > them.
> > >
> > > Great! If I remember your transformer sorts out tags that have
> > > different language attributes than the selected language, right?
> > > --
> > > Torsten
> >
> > Well, that is not the one I was talking in message above. I have that
> > kind of sorting Transformer also, which I send long time ago to
> > cocoon-dev. Anyway i18nTransformer gets translations from another xml
> > file, makes dictionary out of it and substitutes all occurrences of text
> > between <tr> tags that are in dictonary in wanted language.
> >
> > LangSelector is action which can be used to select different xml files
> > according to language. eg.
> > <map:match pattern="page">
> >       <map:act type="lang_select">
> >               <map:generate src="site/page_{1}.xml"/>
> >       </map:act>
> >       ...
> >
> > {1} = gets to its value language parameter en,fi,sv...
> 
> Ok... great anyway ;) ... Do you still use your sorting transformer?

Nope. Problem in the beginning is that it bloats xml-source with all
different translations. And it's easier for translator(s) to have clean
translation file(s) than file with other markup inside.

> What came to my mind when reading about it was to use it as a security
> mechanism inside C2. With C1 we use something like that via XSP.
> 
> We are able give each tag a userlevel or role and it depends on
> the authentification what is shown.
> 
> <page>
>    <content>
>       <somesecuretext userlevel="2-3">
>          confidential
>       </somesecuretext>
>       insecure text
>    </content>
> </page>
> 
> What about your transformer filtering the tags?
> --
> Torsten

That would be possible. 
Anyway in C2 utils to handle user roles and userlevels are needed. Maybe
the cooperation with Turbine project will give those utils.

 Lassi
Mime
View raw message