Hi
I build a questionnaire tool. I have three type of answers, each stored in a separate type of template. Now I can create questionnaires (fragebogen) and ther arrange the questions and their order using a repeatable region.
In the repeatable region only the id of the question is stored.
Every answer is related to the questionnaire (fragebogen), to the question (frage), to the customer (anfrager) and to the craftsman (anbieter).
See attached file with the templates ...
No I want to evaluate the answers to specific questions.
I tried like that:
The problem is, since the editables "anfrage", "frage", "fragebogen", ... are of type relation, I cannot access thir values using "<cms:show ... />". Since I need to filter out answers related to a specific "frage" ans a specific "fragebogen", I have no chance to realize it with <cms:related_pages ... > tag.
Any idea how to filter similar to custom_field=... or how to get out the values stored in the relation fields with php?
I'm totally stuck ...
I build a questionnaire tool. I have three type of answers, each stored in a separate type of template. Now I can create questionnaires (fragebogen) and ther arrange the questions and their order using a repeatable region.
In the repeatable region only the id of the question is stored.
Every answer is related to the questionnaire (fragebogen), to the question (frage), to the customer (anfrager) and to the craftsman (anbieter).
See attached file with the templates ...
No I want to evaluate the answers to specific questions.
I tried like that:
- Code: Select all
<table class="table table-bordered table-striped">
<thead>
<tr>
<th>Datum</th>
<th>Anbieter</th>
<th>Anfrager</th>
<th><cms:get_custom_field 'frage' masterpage='befragung/fragen.php' id=frage_id limit='1' /></th>
</tr>
</thead>
<tbody>
<cms:pages masterpage='befragung/antworten_offertstellung.php' custom_field="fragebogen==<cms:show fragebogen_id />|frage=<cms:show frage_id />" orderby='publish_date' order='desc'>
<cms:set anfrager_name="<cms:related_pages 'anfrage'><cms:show nachname />, <cms:show vorname /></cms:related_pages>" />
<tr>
<td><cms:show k_page_date /></td>
<td><cms:show k_page_title /></td>
<td><cms:show anfrager_name /></td>
<td><cms:show antwort /></td>
</tr>
</cms:pages>
</tbody>
</table>
The problem is, since the editables "anfrage", "frage", "fragebogen", ... are of type relation, I cannot access thir values using "<cms:show ... />". Since I need to filter out answers related to a specific "frage" ans a specific "fragebogen", I have no chance to realize it with <cms:related_pages ... > tag.
Any idea how to filter similar to custom_field=... or how to get out the values stored in the relation fields with php?
I'm totally stuck ...