I have the result of a semantic query. For one of the properties, a comma separated list, I want to separate each item and pass it as a parameter to a template. However, I am struggling to find a way to do this.
For example;
Query:
{{#ask: [[Category:Something]] [[Has title::Somethingelse]]
| mainlabel=-
| ?Has property
| link=none
| format=template
| template=plainText
}}
The plainText template will have the result, which is a comma separated list. Now, from the plainText template I would like to separate the comma separated list and put each value as a parameter into another template.
I have tried using {{#arraydefine:key|values|delimiter|options}}
but when I pass {{#arrayindex:key|0}}
to the template, the value is not passed. The whole array is passed separated by 0. I have also tried using {{#vardefine:
etc but this also does not pass the variable.
My question boils down to, how to pass a variable to a template?
Thanks,