Smart templates in Advanced Views
Last updated
<? foreach ($categories["value"] as $index => $term_item): ?>
<a target="<?= esc_html($term_item["target"]); ?>" class="acf-view__categories-link" href="<?= esc_html($term_item["value"]); ?>">
<?= esc_html($term_item["linkLabel"] ?: $term_item["title"]); ?>
</a>
<? endforeach; ?>{% for index, term_item in categories.value %}
<a target="{{ term_item.target }}" class="acf-view__categories-link" href="{{ term_item.value }}">
{{ term_item.linkLabel|default(term_item.title) }}
</a>
{% endfor %}@foreach ($categories["value"] as $index => $term_item)
<a target="{{ $term_item["target"] }}" class="acf-view__categories-link" href="{{ $term_item["value"] }}">
{{ $term_item["linkLabel"] ?: $term_item["title"] }}
</a>
@endforeach