[opencms-dev] include tag problem
Y. Glebov
yglebov at eclipse-sp.com
Sun Aug 13 12:07:13 CEST 2006
Hello, thanks for the answer, but still
I need to display a page in locale, that differs from locale of all other
elements on this page, how can I define it?
Yuriy.
-----Original Message-----
From: opencms-dev-bounces at opencms.org
[mailto:opencms-dev-bounces at opencms.org] On Behalf Of Pavel Peringer
Sent: Saturday, August 12, 2006 2:42 PM
To: The OpenCms mailing list
Subject: Re: [opencms-dev] include tag problem
Hello
I am using param too with cms.include ("function" for tag <cms:include>):
Map params = new HashMap();
params.put(name, value);
cms.include(file, element, params);
in jsp get value with request.getParameter(name);
cms.getRequestContext().getLocale() returns locale defined on resource,
ie you have one english site so set property locale = en, another in
french so set locale = fr and cmsRequest returns this value, not
parameter value from parent jsp.
HTH
Pavel Peringer
> Hi guys.
>
> Have a little problem here.
>
> Have a template file that contains this lines:
>
> <cms:include page="../elements/promo_block.jsp">
>
> <cms:param name="__locale">en</cms:param>
>
> </cms:include>
>
> And element file that contains:
>
> org.opencms.jsp.CmsJspActionElement cms =
>
> new org.opencms.jsp.CmsJspActionElement(pageContext, request, response);
>
> String locale = cms.getRequestContext().getLocale().toString();
>
> out.println(locale);
>
> Locale appears not "en", and content from file is displayed in another
> language that English.
>
> Locale "en" properly added to locales list in config file.
>
> What's the problem?
>
> Thanks, Yuri.
>
>------------------------------------------------------------------------
>
>
>_______________________________________________
>This mail is sent to you from the opencms-dev mailing list
>To change your list options, or to unsubscribe from the list, please visit
>http://lists.opencms.org/mailman/listinfo/opencms-dev
>
--
Pavel Peringer Qbizm technologies, a.s.
programator ... the art of software.
____________________________________________________________________
www.qbizm-technologies.cz www.qbizm.cz www.qbizm-services.cz
_______________________________________________
This mail is sent to you from the opencms-dev mailing list
To change your list options, or to unsubscribe from the list, please visit
http://lists.opencms.org/mailman/listinfo/opencms-dev
More information about the opencms-dev
mailing list