Hi
I’m building a multilanguage website with 3 context (one for each language, mydomain.com/de mydomain.com/en). The context share the same templates, chunks, assets, snippets. I like the way hk_modx described multilanguage websites, see here:
http://modxcms.com/forums/index.php/topic,43806.msg298361.html#msg298361
My goal is currently to have a language menu (linking between context) that points to each site_start, but I didn’t find an elegant solution yet.
At this point hardcoded a little language navigation (see exmaple below) and I wondered if there could be a more flexible way that grabs all the site_starts from each context and builds a wayfinder like navigation.
<div class="language">
<ul>
<li[[!if? &subject=`[[++site_start]]` &operand=`8` &then=` class="active"`]]>
<a href="[[~8]]">English</a>
</li>
<li[[!if? &subject=`[[++site_start]]` &operand=`2` &then=` class="active"`]]>
<a href="[[~2]]">Deutsch</a>
</li>
<li class="last[[!if? &subject=`[[++site_start]]` &operand=`68` &then=` active`]]">
<a href="[[~68]]">Russian</a>
</li>
</ul>
</div>
Currently feels like I handcode wayfinder myself. Has anybody come up with a more elegant solution than this?