Mega Menu

Highlighted
Tourist
7 0 1

Hello guy's

 

How do I go about getting a collection image from child links? 

This works fine on the parent links but I need this to work on child links.

 

Capture1.JPG

 

{% for child_link in linklists[child_list_handle].links %}

                      {% assign grand_child_list_handle = child_link.title | handle %}

                      {% if link.type == "collection_link" and link.object.image %}
                          {{ link.object.image | img_url: 'small' | img_tag }}
                      {% endif %}


                      {% if linklists[grand_child_list_handle] and linklists[grand_child_list_handle].links.size > 0 %}
                      <li class="has_dropdown">
                          {{ child_link.title | link_to: child_link.url }}
                         <ul>
                          {% for grand_child_link in linklists[grand_child_list_handle].links %}
                          <li>
                            {{ grand_child_link.title | link_to: grand_child_link.url }}
                          </li>
                          {% endfor %}
                        </ul>
                      </li>
                      {% else %}
                      <li class="child_item">
                        {{ child_link.title | link_to: child_link.url }} 
                      </li>
                      {% endif %}
                    {% endfor %} 
0 Likes