Upload and show a image with Flex-Directory

Hello,

I’ve modified the Flex-Directory plugin with my own label.
Now, I’m trying to add a label to upload an image.
It’s working in the admin, the label is here and the file is uploaded.
But the image don’t appear in the page.

I’ve had these lines in the site.html.twig file

{% if entry.captures %}
       <p><span class="name">{{ entry.captures }}</span></p>
{% endif %}  

And these lines in the entries-list.html.twig

<td>
      {{ entry.description }}
</td>

What’s wrong with this ?
Any help please ?

Thanks,

andre_ani

I add this to the site.html.twig file but it’s not working.

{% if entry.captures %}

{{ entry.captures }}



{% endif %}

I finally find this https://learn.getgrav.org/16/cookbook/twig-recipes#displaying-an-image-uploaded-in-a-file-field

But the image is not appear… If I look at the code of the page, I have array in place of the name of the image.

I don’t understand this code ```
{{ page.media[header.yourfilefield|first.name] }}


In the home page, I want to display the result of the Flex-directory plugin.
The name of the form for the file is {{ entry.captures }}
All of the other items are displaying. I don't know who to access to the image that are upload in /user/data/flex-directory/files/ with random name.

Any suggestions please ?

It’s working, finally, I found the solution

{% for key in entry.captures|keys %}
Card image cap
{% endfor %}