I had the same need and overwrote the getTitle() method (by subclassing JspPortlet in my case). Left for me is now to find the language/locale from somewhere to pass on to one of the Localization.getString(String,...) methods. Any pointers on how to get that inside the getTitle() method?

--
Kim Thrysøe


Fabien Toral wrote:

ok, i see what to do in AbstractPortlet.
i will try later and let you know if it works.

thanks.


Paul Spencer wrote:

Fabien,
I think this can be done in the portlets, i.e. AbstractPortlet, getTitle(). This method is called by the portlet instance wrapper. Assuming your portlet knows how to localize a string, language and country should be accessible via rundata, then the string will be localized.

Note, a localize title can be in the localized psml, which means the portlet does not have to localize the title. This also assumes the user is using a localize psml and not default.


Paul Spencer

Fabien Toral wrote:

Hi list,

has anyone tried to localize the portlet titles ?
Is there a way to do that thing simply, or do we have to develop some wrapper class ?

In our case we have role based PSML and we don't want to use language fallback setting.

thanks for any solution.


--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>



--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to