Closed NicoHood closed 3 years ago
I also noticed that site.title
and base_url_absolute
are also not available in those email templates. I am still not sure why this happens, can you help?
The reason is: I want to list the form attachments in the email sent via data.html.twig
:
{% elseif field.type == 'file' %}
{% set files = form.value(scope ~ field.name) %}
<ul>
{% for file in files %}
<li><a href="{{ base_url_absolute }}/{{ file.path }}">{{ file.name }} ({{ file.size}} Bytes)</a></li>
{% endfor %}
</ul>
Try grav.config.site.title
and grav.base_url_absolute
.
Thanks a lot for the tip! It solved one of my issues!
Can you please have a look at the PR again? It is still relevant though as mentioned here: https://github.com/getgrav/grav-plugin-form/issues/127
Related: https://github.com/getgrav/grav-plugin-form/issues/127