I turned off caching of documents, which makes the website available again. However it seems to be a big bug (or silly typo?) and it’s really more of a workaround then a fix, so I’m still wondering what could be done to fix this.
After disabling caching, I started to work with a YAMS + Wayfinder combo to build a menu (using
http://svn.modxcms.com/docs/pages/viewpage.action?pageId=13205620 to replace the default templates), however that (once again...) results in a blank page being displayed. (with no response/source in the Net tab of Firebug)
When I put the contents of the tpl files in a chunk, call that instead, and use regular text instead of the YAMS snippet calls in the template, the page once again shows.
Perhaps, a snippet problem?
<?php
require( $modx->config['base_path'] . 'assets/modules/yams/yams.snippet.inc.php' );
?>
The body part of the template now:
<body>
[*content*]
[[Wayfinder? &level=`1` &startId=`0` &rowTpl=`@FILE:assets/modules/yams/tpl/wayfinder/doc/row.tpl`]]
[[YAMS? &get=`repeat` &beforetpl=`@code:<div id="taalselectie">` &repeattpl=`talen_vlag_overig` ¤ttpl=`talen_vlag_huidig` &aftertpl=`@code:</div>`]]
</body>
When there are no snippets calls to YAMS in the .tpl file/chunk it works and displays the content properly (although the menu is monolingual). The language selector works like it should.
Some more checks:
This
does not work and result in a blank page (default row.tpl):
<li[+wf.id+][+wf.classes+]>
<a href="(yams_doc:[+wf.docid+])" title="[[YAMS? &get=`data` &docid=`[+wf.docid+]` &from=`pagetitle`]]" [+wf.attributes+]>[[YAMS? &get=`data` &docid=`[+wf.docid+]` &from=`menutitle`]]</a>
[+wf.wrapper+]
</li>
This
does work and shows the page, however it results in all links being {link} which aint too useful. The links (urls) are made correctly tho.
<li[+wf.id+][+wf.classes+]>
<a href="(yams_doc:[+wf.docid+])" title="{title}" [+wf.attributes+]>{link}</a>
[+wf.wrapper+]
</li>
Almost-a-fix:
I was looking through the placeholders list of YAMS, and *nearly* got a fix... I found that this outputs the pagetitle for the language identified by "nl".. however it’s not multilingual *yet*.
((yams_data:[+wf.docid+]:pagetitle_nl))
So I went looking for the current language tag placeholder, which is (yams_id). Which would mean:
((yams_data:[+wf.docid+]:pagetitle_(yams_id)))
Which outputs the call, like: ((yams_data:4:pagetitle_nl)), but does not process it, which is the final step I’m stuck with as I can imagine that will probably involve changing the snippet - something I’m not too fond of doing myself... Anybody any ideas?