I name JSON like {“images”: [“IMG1″,”IMG2″,”IMG3”]} “unnamed array”. This is because this is just a collection of items in the array. And not a collection where each item has a key.
The challenge is to display this collection:
- In the free Version and the PRO-Version prior to 2.0.15 this could be done by “{subloop-array:images:10}{0} {1}{/subloop-array:images}” where “{0}” is the first item an so one.But if the number of items is not fixed this template-syntax can’t display a flexible number of items.
- The PRO-Version from version 2.0.15 on solves this by “{images.jcix:left##right##number##}”
This shows the items 1…number (if number=-1: all) of the array and adds “left” and “right” before and after the JSON-value.
Example:
- JSON:
{“images”:
[“IMG1″,”IMG2″,”IMG3”],
“moretext”: “more chars”
} - Template:{moretext}<br>{images.jcix:aaa##bbb##1##}<br>{images.jcix:ccc##ddd##2##}