-
FEATURED COMPONENTS
First time here? Check out the FAQ!
hi guys i have a problem on internalization i have a page whit table with series of pair label textbox(user insert this value) when i click on button "english version" change locale and reload page with instruction
execution.sendRedirect("");
but in this case i'm lost textbox value (if is present)
how to i reload labels content without reload all page?
i try with Labels.reset
http://www.zkoss.org/javadoc/3.0.7/zcommon/org/zkoss/util/resource/Labels.html#reset()
but doesn't work.
bye
tnx for your tips. but i have more labels. is exists a metod to select only one component kind in page? anything like
component.getChildren(typeOfComponent)
bye
Hi Vicenzo, this may help:
Locale prefer_locale = new Locale(en);//The new Locale
session.setAttribute(org.zkoss.web.Attributes.PREFERRED_LOCALE, prefer_locale);
Clients.reloadMessages(prefer_locale);
org.zkoss.util.Locales.setThreadLocal(prefer_locale);
//Reload all components labels
LBLHola.setValue(Labels.getLabel("hola"));
LHNombre.setValue(Labels.getLabel("nombre"));
//etc.
Asked: 2013-01-11 12:43:19 +0800
Seen: 81 times
Last updated: Jan 22 '13