You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@lenya.apache.org by Wolfgang Jeltsch <zs...@acme.softbase.org> on 2008/06/16 00:12:53 UTC

changing the publication title

Hello,

I want to change the title of my publication which is shown on the top of 
every page.  I discovered that this title is set by cmsui_de.xml (for 
German).  So I copied the file cmsui_de.xml of the default publication into 
the corresponding directory of my publication and changed it accordingly.  
Surprisingly, my pages didn’t change.  So I copied also the XSLT file which 
uses the publication title (page2xhtml.xsl) but this still didn’t help.

Any hints?

Best wishes,
Wolfgang

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@lenya.apache.org
For additional commands, e-mail: user-help@lenya.apache.org


Re: changing the publication title

Posted by Andreas Hartmann <an...@apache.org>.
Wolfgang Jeltsch schrieb:

[…]

> Puuh, I cannot imagine that it’s that complicated to just change the website 
> title.  Do the Lenya developers really intend that all publications derived 
> from the default publication show “Welcome to the Default Publication from 
> the Lenya community!” on each page?

Sure, that's our fail-safe marketing strategy :)

> Or how should I change the title if not via overwriting the catalogues?

There are various options:

- put a named template into an XSLT that you import via fallback
- use the properties module
- use a dedicated document (with translations) for reusable snippets
- use the label of a dedicated site node and the navigation module
- …

-- Andreas


-- 
Andreas Hartmann, CTO
BeCompany GmbH
http://www.becompany.ch
Tel.: +41 (0) 43 818 57 01


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@lenya.apache.org
For additional commands, e-mail: user-help@lenya.apache.org


Re: changing the publication title

Posted by Wolfgang Jeltsch <zs...@acme.softbase.org>.
Am Sonntag, 22. Juni 2008 20:42 schrieb Andreas Hartmann:
> Wolfgang Jeltsch schrieb:
> > Am Montag, 16. Juni 2008 12:25 schrieb Andreas Hartmann:
> >> Wolfgang Jeltsch schrieb:
> >>
> >> […]
> >>
> >>> I want to change the title of my publication which is shown on the top
> >>> of every page.  I discovered that this title is set by cmsui_de.xml
> >>> (for German).  So I copied the file cmsui_de.xml of the default
> >>> publication into the corresponding directory of my publication and
> >>> changed it accordingly. Surprisingly, my pages didn’t change.
> >>
> >> It's not possible to use different values for the same i18n message in
> >> different publications, since all values are cached during startup.
> >>
> >> If you need publication-specific i18n messages, you have to use
> >> publication-specific i18n catalogues.
> >
> > I don’t understand this.  I thought by creating a file cmsui_de.xml in my
> > publication, I create a separate catalogue and the fallback mechanism
> > would choose this cmsui_de.xml file instead of the one of the default
> > publication.
>
> Unfortunately the (aggregate-)fallback:// mechanism can't be applied to
> i18n, at least not without serious performance degradation. The i18n
> transformer uses a single (global) URI to reference the catalogue, and
> the first result of the request to this URI is cached. So, the first
> requested publication would win, and all subsequently requested
> publications would use the same i18n messages.
>
> You'd have to switch off caching (which will make the application really
> slow) or declare a dedicated transformer for each publication.
>
> A possible solution would be an enhanced i18n transformer which
>
> * builds the catalogue URI dynamically based on the current publication
> * maintains a set of catalogues (one per publication)
> * caches all these catalogues

Puuh, I cannot imagine that it’s that complicated to just change the website 
title.  Do the Lenya developers really intend that all publications derived 
from the default publication show “Welcome to the Default Publication from 
the Lenya community!” on each page?  Or how should I change the title if not 
via overwriting the catalogues?

> […]

Best wishes,
Wolfgang

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@lenya.apache.org
For additional commands, e-mail: user-help@lenya.apache.org


Re: changing the publication title

Posted by so...@apache.org.
On 6/22/08, Andreas Hartmann <an...@apache.org> wrote:
> Wolfgang Jeltsch schrieb:
> > I don't understand this.  I thought by creating a file cmsui_de.xml in my
> > publication, I create a separate catalogue and the fallback mechanism would
> > choose this cmsui_de.xml file instead of the one of the default publication.
>
>  Unfortunately the (aggregate-)fallback:// mechanism can't be applied to
> i18n, at least not without serious performance degradation. The i18n
> transformer uses a single (global) URI to reference the catalogue, and the
> first result of the request to this URI is cached. So, the first requested
> publication would win, and all subsequently requested publications would use
> the same i18n messages.
>
>  You'd have to switch off caching (which will make the application really
> slow) or declare a dedicated transformer for each publication.
>
>  A possible solution would be an enhanced i18n transformer which
>  * builds the catalogue URI dynamically based on the current publication
>  * maintains a set of catalogues (one per publication)
>  * caches all these catalogues
>
>  What do the others think?
>  -- Andreas

We can (and probably did) discuss this on the Dev ML.  My goal is for
the XMLSerializer to translate using Publication/Module-specific i18n
catalogues without changing undefined elements, then the HTML
Serializer finishes transforming all i18n elements with the
"untranslated" message if necessary.  This eliminates the need for
developers to remember to call the I18nTransformer (and likely upset
people believing serialization is not a transformation) while storing
i18n catalogues with their functions.   The i18n catalogue cache will
contain separate entries for every Module in every Publication plus
the global Modules.  No global catalogue will exist -- (almost)
everything will belong to a Module including all i18n configuration
since i18n translation is useless without some text to translate.  The
publication title can be overridden in a publication-specific module's
catalogue.

For the OP:
Just edit page2xhtml.xsl to change the <td id="publication-title">
section to display what you want.  Use i18n elements named with your
publication-id if needed e.g. "mypub-publication-title".

solprovider

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@lenya.apache.org
For additional commands, e-mail: user-help@lenya.apache.org


Re: changing the publication title

Posted by Andreas Hartmann <an...@apache.org>.
Wolfgang Jeltsch schrieb:
> Am Montag, 16. Juni 2008 12:25 schrieb Andreas Hartmann:
>> Wolfgang Jeltsch schrieb:
> 
>> […]
> 
>>> I want to change the title of my publication which is shown on the top of
>>> every page.  I discovered that this title is set by cmsui_de.xml (for
>>> German).  So I copied the file cmsui_de.xml of the default publication
>>> into the corresponding directory of my publication and changed it
>>> accordingly. Surprisingly, my pages didn’t change.
>> It's not possible to use different values for the same i18n message in
>> different publications, since all values are cached during startup.
>>
>> If you need publication-specific i18n messages, you have to use
>> publication-specific i18n catalogues.
> 
> I don’t understand this.  I thought by creating a file cmsui_de.xml in my 
> publication, I create a separate catalogue and the fallback mechanism would 
> choose this cmsui_de.xml file instead of the one of the default publication.

Unfortunately the (aggregate-)fallback:// mechanism can't be applied to 
i18n, at least not without serious performance degradation. The i18n 
transformer uses a single (global) URI to reference the catalogue, and 
the first result of the request to this URI is cached. So, the first 
requested publication would win, and all subsequently requested 
publications would use the same i18n messages.

You'd have to switch off caching (which will make the application really 
slow) or declare a dedicated transformer for each publication.

A possible solution would be an enhanced i18n transformer which

* builds the catalogue URI dynamically based on the current publication
* maintains a set of catalogues (one per publication)
* caches all these catalogues

What do the others think?

> At least this sort of overwriting works with CSS stylesheets.

Yes, that's because the URIs to the stylesheets are built dynamically 
based on the current publication.

-- Andreas


-- 
Andreas Hartmann, CTO
BeCompany GmbH
http://www.becompany.ch
Tel.: +41 (0) 43 818 57 01


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@lenya.apache.org
For additional commands, e-mail: user-help@lenya.apache.org


Re: changing the publication title

Posted by Wolfgang Jeltsch <zs...@acme.softbase.org>.
Am Montag, 16. Juni 2008 12:25 schrieb Andreas Hartmann:
> Wolfgang Jeltsch schrieb:

> […]

> > I want to change the title of my publication which is shown on the top of
> > every page.  I discovered that this title is set by cmsui_de.xml (for
> > German).  So I copied the file cmsui_de.xml of the default publication
> > into the corresponding directory of my publication and changed it
> > accordingly. Surprisingly, my pages didn’t change.
>
> It's not possible to use different values for the same i18n message in
> different publications, since all values are cached during startup.
>
> If you need publication-specific i18n messages, you have to use
> publication-specific i18n catalogues.

I don’t understand this.  I thought by creating a file cmsui_de.xml in my 
publication, I create a separate catalogue and the fallback mechanism would 
choose this cmsui_de.xml file instead of the one of the default publication.  
At least this sort of overwriting works with CSS stylesheets.

Best wishes,
Wolfgang

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@lenya.apache.org
For additional commands, e-mail: user-help@lenya.apache.org


Re: changing the publication title

Posted by Andreas Hartmann <an...@apache.org>.
Wolfgang Jeltsch schrieb:
> Hello,
> 
> I want to change the title of my publication which is shown on the top of 
> every page.  I discovered that this title is set by cmsui_de.xml (for 
> German).  So I copied the file cmsui_de.xml of the default publication into 
> the corresponding directory of my publication and changed it accordingly.  
> Surprisingly, my pages didn’t change.

It's not possible to use different values for the same i18n message in 
different publications, since all values are cached during startup.

If you need publication-specific i18n messages, you have to use 
publication-specific i18n catalogues.

-- Andreas



-- 
Andreas Hartmann, CTO
BeCompany GmbH
http://www.becompany.ch
Tel.: +41 (0) 43 818 57 01


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@lenya.apache.org
For additional commands, e-mail: user-help@lenya.apache.org