[opencms-dev] Locale macro in XSD schema

Paul-Inge Flakstad flakstad at npolar.no
Mon Feb 18 11:22:50 CET 2013


Hi Arturo,

Sorry I'm not answering your question per se, but I'm just curious; *must* your categories be organized like /sites/default/_categories/__LOCALE__/?

We do have a multi-language site and use categories, but have organized them this way: /sites/default/__LOCALE__/_categories/. To me, this seems to be the most convenient approach.

The downside:
The categories must be defined separately for each locale. In our case the category folders must have identical names, to enable easy switching between languages. (So in other words, everything should be identical, except for the Title property.)

The upside:
It works like you want it to (I think). The categories are localized to the correct language both in the widget when editing pages and on the screen when viewing the site.

A live example from our site:
http://www.npolar.no/en/news/. Category filters to the right. Language switch next to the site search (the flag icon).

Cheers,
Paul

-----Original Message-----
From: opencms-dev-bounces at opencms.org [mailto:opencms-dev-bounces at opencms.org] On Behalf Of Arturo Martín Lladó
Sent: 15. februar 2013 14:27
To: The OpenCms mailing list
Subject: [opencms-dev] Locale macro in XSD schema

Hi, list.

Is there available any locale macro for using it in XSD schemas?

I'd like to do something like this:

	<layouts>
                [...]
                <layout element="Categoria" widget="CategoryWidget"
configuration="category=/_categories/__LOCALE_MACRO___/tipoDocumento/|onlyleafs=true"/>
	</layouts>

This is because our categories tree is organized this way:
/sites/default/_categories/__LOCALE__/...

Kind regards.

--
Arturo Martín Lladó
_______________________________________________
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/cgi-bin/mailman/listinfo/opencms-dev






More information about the opencms-dev mailing list