Hello,
I want to add image file in header like this image.
[ what I want ]
However, I don’t know how to get the collection metafield file data to header. I tried this code, but It said “no image”. Is there a way to get the collection metafield to header?
[ the collection metafield file ]
[ code ]
{%- if link.links != blank or small_promo_count > 0 -%}
{% if use_columns and link.levels == 1 %}
- {% for child_link in link.links %}
{{- child_link.title | escape -}}
{% endfor %}
{% else %}
{% for child_link in link.links %}
- {{- child_link.title | escape -}}
{% if child_link.links != blank %}
{% render 'icon-toggle-menu', stroke_width: 1.3 %}
{% endif %}
{% if child_link.links != blank %}
{% for child_child_link in child_link.links %}
- {{ collection.metafields.custom.menuthumnail | img_tag }}
- {{ child_child_link.title | escape }}
{% endfor %}
{% endif %}
{% endfor %}
{% endif %}
[ result ]




