[Hippo-cms7-user] HippoNode.getLocalizedName()

Francesco Chicchiriccò francesco.chicchiricco at everett.it
Thu May 6 17:50:00 CEST 2010


Hi there,
I am using the latest tag from 7.3 (2.12.09) and I am experiencing  
something strange related to HippoNode.getLocalizedName().

As far as I've understood, this method is meant to be called every  
time that you have a node that has "hippo:translated" as mixin, with  
one or more "hippo:translation" child nodes.
The expected behaviour should be - if I've understood correctly - that  
when I do something like

((HippoNode) hippoBean).getLocalizedName()

I got the translation of that node's label in Locale.getDefault() or  
English as fallback.

This thing seems to work fine for documents but has some troubles with  
folders: in my tests the first hippo:translation child node is always  
returned as localized label.

Moreover, I've checked at [1], from row 120, that the CMS application  
does not use the provided HippoNode.getLocalizedName(), but does a  
manual discover of available translations.

Now my question is: what is the recommended approach? Is there  
something relevant why getLocalizedName() is not working for folders?

Thanks.

[1] http://svn.hippocms.org/repos/hippo/hippo-ecm/tags/Tag-HREPTWO-v2_12_09/frontend/engine/src/main/java/org/hippoecm/frontend/i18n/model/NodeTranslator.java



More information about the Hippo-cms7-user mailing list